Class Volume
java.lang.Object
com.azure.resourcemanager.containerinstance.models.Volume
- All Implemented Interfaces:
com.azure.json.JsonSerializable<Volume>
The properties of the volume.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGet the azureFile property: The Azure File volume.emptyDir()Get the emptyDir property: The empty directory volume.static VolumefromJson(com.azure.json.JsonReader jsonReader) Reads an instance of Volume from the JsonReader.gitRepo()Get the gitRepo property: The git repo volume.name()Get the name property: The name of the volume.secret()Get the secret property: The secret volume.com.azure.json.JsonWritertoJson(com.azure.json.JsonWriter jsonWriter) voidvalidate()Validates the instance.withAzureFile(AzureFileVolume azureFile) Set the azureFile property: The Azure File volume.withEmptyDir(Object emptyDir) Set the emptyDir property: The empty directory volume.withGitRepo(GitRepoVolume gitRepo) Set the gitRepo property: The git repo volume.Set the name property: The name of the volume.withSecret(Map<String, String> secret) Set the secret property: The secret volume.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.azure.json.JsonSerializable
toJson, toJson, toJsonBytes, toJsonString
-
Constructor Details
-
Volume
public Volume()Creates an instance of Volume class.
-
-
Method Details
-
name
Get the name property: The name of the volume.- Returns:
- the name value.
-
withName
Set the name property: The name of the volume.- Parameters:
name- the name value to set.- Returns:
- the Volume object itself.
-
azureFile
Get the azureFile property: The Azure File volume.- Returns:
- the azureFile value.
-
withAzureFile
Set the azureFile property: The Azure File volume.- Parameters:
azureFile- the azureFile value to set.- Returns:
- the Volume object itself.
-
emptyDir
Get the emptyDir property: The empty directory volume.- Returns:
- the emptyDir value.
-
withEmptyDir
Set the emptyDir property: The empty directory volume.- Parameters:
emptyDir- the emptyDir value to set.- Returns:
- the Volume object itself.
-
secret
Get the secret property: The secret volume.- Returns:
- the secret value.
-
withSecret
Set the secret property: The secret volume.- Parameters:
secret- the secret value to set.- Returns:
- the Volume object itself.
-
gitRepo
Get the gitRepo property: The git repo volume.- Returns:
- the gitRepo value.
-
withGitRepo
Set the gitRepo property: The git repo volume.- Parameters:
gitRepo- the gitRepo value to set.- Returns:
- the Volume object itself.
-
validate
public void validate()Validates the instance.- Throws:
IllegalArgumentException- thrown if the instance is not valid.
-
toJson
- Specified by:
toJsonin interfacecom.azure.json.JsonSerializable<Volume>- Throws:
IOException
-
fromJson
Reads an instance of Volume from the JsonReader.- Parameters:
jsonReader- The JsonReader being read.- Returns:
- An instance of Volume if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.
- Throws:
IllegalStateException- If the deserialized JSON object was missing any required properties.IOException- If an error occurs while reading the Volume.
-