VMExtension Class

  • java.lang.Object
    • com.azure.resourcemanager.batch.models.VMExtension

Implements

public final class VMExtension
implements JsonSerializable<VMExtension>

The configuration for virtual machine extensions.

Constructor Summary

Constructor Description
VMExtension()

Creates an instance of VMExtension class.

Method Summary

Modifier and Type Method and Description
Boolean autoUpgradeMinorVersion()

Get the autoUpgradeMinorVersion property: Indicates whether the extension should use a newer minor version if one is available at deployment time.

Boolean enableAutomaticUpgrade()

Get the enableAutomaticUpgrade property: Indicates whether the extension should be automatically upgraded by the platform if there is a newer version of the extension available.

static VMExtension fromJson(JsonReader jsonReader)

Reads an instance of VMExtension from the JsonReader.

String name()

Get the name property: The name of the virtual machine extension.

Object protectedSettings()

Get the protectedSettings property: The extension can contain either protectedSettings or protectedSettingsFromKeyVault or no protected settings at all.

List<String> provisionAfterExtensions()

Get the provisionAfterExtensions property: Collection of extension names after which this extension needs to be provisioned.

String publisher()

Get the publisher property: The name of the extension handler publisher.

Object settings()

Get the settings property: JSON formatted public settings for the extension.

JsonWriter toJson(JsonWriter jsonWriter)
String type()

Get the type property: The type of the extensions.

String typeHandlerVersion()

Get the typeHandlerVersion property: The version of script handler.

void validate()

Validates the instance.

VMExtension withAutoUpgradeMinorVersion(Boolean autoUpgradeMinorVersion)

Set the autoUpgradeMinorVersion property: Indicates whether the extension should use a newer minor version if one is available at deployment time.

VMExtension withEnableAutomaticUpgrade(Boolean enableAutomaticUpgrade)

Set the enableAutomaticUpgrade property: Indicates whether the extension should be automatically upgraded by the platform if there is a newer version of the extension available.

VMExtension withName(String name)

Set the name property: The name of the virtual machine extension.

VMExtension withProtectedSettings(Object protectedSettings)

Set the protectedSettings property: The extension can contain either protectedSettings or protectedSettingsFromKeyVault or no protected settings at all.

VMExtension withProvisionAfterExtensions(List<String> provisionAfterExtensions)

Set the provisionAfterExtensions property: Collection of extension names after which this extension needs to be provisioned.

VMExtension withPublisher(String publisher)

Set the publisher property: The name of the extension handler publisher.

VMExtension withSettings(Object settings)

Set the settings property: JSON formatted public settings for the extension.

VMExtension withType(String type)

Set the type property: The type of the extensions.

VMExtension withTypeHandlerVersion(String typeHandlerVersion)

Set the typeHandlerVersion property: The version of script handler.

Methods inherited from java.lang.Object

Constructor Details

VMExtension

public VMExtension()

Creates an instance of VMExtension class.

Method Details

autoUpgradeMinorVersion

public Boolean autoUpgradeMinorVersion()

Get the autoUpgradeMinorVersion property: Indicates whether the extension should use a newer minor version if one is available at deployment time. Once deployed, however, the extension will not upgrade minor versions unless redeployed, even with this property set to true.

Returns:

the autoUpgradeMinorVersion value.

enableAutomaticUpgrade

public Boolean enableAutomaticUpgrade()

Get the enableAutomaticUpgrade property: Indicates whether the extension should be automatically upgraded by the platform if there is a newer version of the extension available.

Returns:

the enableAutomaticUpgrade value.

fromJson

public static VMExtension fromJson(JsonReader jsonReader)

Reads an instance of VMExtension from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

An instance of VMExtension if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.

Throws:

IOException

- If the deserialized JSON object was missing any required properties.

name

public String name()

Get the name property: The name of the virtual machine extension.

Returns:

the name value.

protectedSettings

public Object protectedSettings()

Get the protectedSettings property: The extension can contain either protectedSettings or protectedSettingsFromKeyVault or no protected settings at all.

Returns:

the protectedSettings value.

provisionAfterExtensions

public List provisionAfterExtensions()

Get the provisionAfterExtensions property: Collection of extension names after which this extension needs to be provisioned.

Returns:

the provisionAfterExtensions value.

publisher

public String publisher()

Get the publisher property: The name of the extension handler publisher.

Returns:

the publisher value.

settings

public Object settings()

Get the settings property: JSON formatted public settings for the extension.

Returns:

the settings value.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

type

public String type()

Get the type property: The type of the extensions.

Returns:

the type value.

typeHandlerVersion

public String typeHandlerVersion()

Get the typeHandlerVersion property: The version of script handler.

Returns:

the typeHandlerVersion value.

validate

public void validate()

Validates the instance.

withAutoUpgradeMinorVersion

public VMExtension withAutoUpgradeMinorVersion(Boolean autoUpgradeMinorVersion)

Set the autoUpgradeMinorVersion property: Indicates whether the extension should use a newer minor version if one is available at deployment time. Once deployed, however, the extension will not upgrade minor versions unless redeployed, even with this property set to true.

Parameters:

autoUpgradeMinorVersion - the autoUpgradeMinorVersion value to set.

Returns:

the VMExtension object itself.

withEnableAutomaticUpgrade

public VMExtension withEnableAutomaticUpgrade(Boolean enableAutomaticUpgrade)

Set the enableAutomaticUpgrade property: Indicates whether the extension should be automatically upgraded by the platform if there is a newer version of the extension available.

Parameters:

enableAutomaticUpgrade - the enableAutomaticUpgrade value to set.

Returns:

the VMExtension object itself.

withName

public VMExtension withName(String name)

Set the name property: The name of the virtual machine extension.

Parameters:

name - the name value to set.

Returns:

the VMExtension object itself.

withProtectedSettings

public VMExtension withProtectedSettings(Object protectedSettings)

Set the protectedSettings property: The extension can contain either protectedSettings or protectedSettingsFromKeyVault or no protected settings at all.

Parameters:

protectedSettings - the protectedSettings value to set.

Returns:

the VMExtension object itself.

withProvisionAfterExtensions

public VMExtension withProvisionAfterExtensions(List provisionAfterExtensions)

Set the provisionAfterExtensions property: Collection of extension names after which this extension needs to be provisioned.

Parameters:

provisionAfterExtensions - the provisionAfterExtensions value to set.

Returns:

the VMExtension object itself.

withPublisher

public VMExtension withPublisher(String publisher)

Set the publisher property: The name of the extension handler publisher.

Parameters:

publisher - the publisher value to set.

Returns:

the VMExtension object itself.

withSettings

public VMExtension withSettings(Object settings)

Set the settings property: JSON formatted public settings for the extension.

Parameters:

settings - the settings value to set.

Returns:

the VMExtension object itself.

withType

public VMExtension withType(String type)

Set the type property: The type of the extensions.

Parameters:

type - the type value to set.

Returns:

the VMExtension object itself.

withTypeHandlerVersion

public VMExtension withTypeHandlerVersion(String typeHandlerVersion)

Set the typeHandlerVersion property: The version of script handler.

Parameters:

typeHandlerVersion - the typeHandlerVersion value to set.

Returns:

the VMExtension object itself.

Applies to