你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

StorageProfile Class

  • java.lang.Object
    • com.azure.resourcemanager.networkcloud.models.StorageProfile

Implements

public final class StorageProfile
implements JsonSerializable<StorageProfile>

StorageProfile represents information about a disk.

Constructor Summary

Constructor Description
StorageProfile()

Creates an instance of StorageProfile class.

Method Summary

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

Reads an instance of StorageProfile from the JsonReader.

OsDisk osDisk()

Get the osDisk property: The disk to use with this virtual machine.

JsonWriter toJson(JsonWriter jsonWriter)
void validate()

Validates the instance.

List<String> volumeAttachments()

Get the volumeAttachments property: The resource IDs of volumes that are requested to be attached to the virtual machine.

StorageProfile withOsDisk(OsDisk osDisk)

Set the osDisk property: The disk to use with this virtual machine.

StorageProfile withVolumeAttachments(List<String> volumeAttachments)

Set the volumeAttachments property: The resource IDs of volumes that are requested to be attached to the virtual machine.

Methods inherited from java.lang.Object

Constructor Details

StorageProfile

public StorageProfile()

Creates an instance of StorageProfile class.

Method Details

fromJson

public static StorageProfile fromJson(JsonReader jsonReader)

Reads an instance of StorageProfile from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

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

osDisk

public OsDisk osDisk()

Get the osDisk property: The disk to use with this virtual machine.

Returns:

the osDisk value.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

validate

public void validate()

Validates the instance.

volumeAttachments

public List<String> volumeAttachments()

Get the volumeAttachments property: The resource IDs of volumes that are requested to be attached to the virtual machine.

Returns:

the volumeAttachments value.

withOsDisk

public StorageProfile withOsDisk(OsDisk osDisk)

Set the osDisk property: The disk to use with this virtual machine.

Parameters:

osDisk - the osDisk value to set.

Returns:

the StorageProfile object itself.

withVolumeAttachments

public StorageProfile withVolumeAttachments(List<String> volumeAttachments)

Set the volumeAttachments property: The resource IDs of volumes that are requested to be attached to the virtual machine.

Parameters:

volumeAttachments - the volumeAttachments value to set.

Returns:

the StorageProfile object itself.

Applies to