VirtualMachineConfiguration Class

  • java.lang.Object
    • com.azure.resourcemanager.workloadssapvirtualinstance.models.VirtualMachineConfiguration

Implements

public final class VirtualMachineConfiguration
implements JsonSerializable<VirtualMachineConfiguration>

Defines the virtual machine configuration.

Constructor Summary

Constructor Description
VirtualMachineConfiguration()

Creates an instance of VirtualMachineConfiguration class.

Method Summary

Modifier and Type Method and Description
static VirtualMachineConfiguration fromJson(JsonReader jsonReader)

Reads an instance of VirtualMachineConfiguration from the JsonReader.

ImageReference imageReference()

Get the imageReference property: The image reference.

OSProfile osProfile()

Get the osProfile property: The OS profile.

JsonWriter toJson(JsonWriter jsonWriter)
void validate()

Validates the instance.

String vmSize()

Get the vmSize property: The virtual machine size.

VirtualMachineConfiguration withImageReference(ImageReference imageReference)

Set the imageReference property: The image reference.

VirtualMachineConfiguration withOsProfile(OSProfile osProfile)

Set the osProfile property: The OS profile.

VirtualMachineConfiguration withVmSize(String vmSize)

Set the vmSize property: The virtual machine size.

Methods inherited from java.lang.Object

Constructor Details

VirtualMachineConfiguration

public VirtualMachineConfiguration()

Creates an instance of VirtualMachineConfiguration class.

Method Details

fromJson

public static VirtualMachineConfiguration fromJson(JsonReader jsonReader)

Reads an instance of VirtualMachineConfiguration from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

An instance of VirtualMachineConfiguration 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.

imageReference

public ImageReference imageReference()

Get the imageReference property: The image reference.

Returns:

the imageReference value.

osProfile

public OSProfile osProfile()

Get the osProfile property: The OS profile.

Returns:

the osProfile value.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

validate

public void validate()

Validates the instance.

vmSize

public String vmSize()

Get the vmSize property: The virtual machine size.

Returns:

the vmSize value.

withImageReference

public VirtualMachineConfiguration withImageReference(ImageReference imageReference)

Set the imageReference property: The image reference.

Parameters:

imageReference - the imageReference value to set.

Returns:

the VirtualMachineConfiguration object itself.

withOsProfile

public VirtualMachineConfiguration withOsProfile(OSProfile osProfile)

Set the osProfile property: The OS profile.

Parameters:

osProfile - the osProfile value to set.

Returns:

the VirtualMachineConfiguration object itself.

withVmSize

public VirtualMachineConfiguration withVmSize(String vmSize)

Set the vmSize property: The virtual machine size.

Parameters:

vmSize - the vmSize value to set.

Returns:

the VirtualMachineConfiguration object itself.

Applies to