Class VirtualMachineSshCredentials
java.lang.Object
com.azure.resourcemanager.machinelearning.models.VirtualMachineSshCredentials
- All Implemented Interfaces:
com.azure.json.JsonSerializable<VirtualMachineSshCredentials>
public final class VirtualMachineSshCredentials
extends Object
implements com.azure.json.JsonSerializable<VirtualMachineSshCredentials>
Admin credentials for virtual machine.
-
Constructor Summary
ConstructorsConstructorDescriptionCreates an instance of VirtualMachineSshCredentials class. -
Method Summary
Modifier and TypeMethodDescriptionstatic VirtualMachineSshCredentialsfromJson(com.azure.json.JsonReader jsonReader) Reads an instance of VirtualMachineSshCredentials from the JsonReader.password()Get the password property: Password of admin account.Get the privateKeyData property: Private key data.Get the publicKeyData property: Public key data.com.azure.json.JsonWritertoJson(com.azure.json.JsonWriter jsonWriter) username()Get the username property: Username of admin account.voidvalidate()Validates the instance.withPassword(String password) Set the password property: Password of admin account.withPrivateKeyData(String privateKeyData) Set the privateKeyData property: Private key data.withPublicKeyData(String publicKeyData) Set the publicKeyData property: Public key data.withUsername(String username) Set the username property: Username of admin account.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
-
VirtualMachineSshCredentials
public VirtualMachineSshCredentials()Creates an instance of VirtualMachineSshCredentials class.
-
-
Method Details
-
username
Get the username property: Username of admin account.- Returns:
- the username value.
-
withUsername
Set the username property: Username of admin account.- Parameters:
username- the username value to set.- Returns:
- the VirtualMachineSshCredentials object itself.
-
password
Get the password property: Password of admin account.- Returns:
- the password value.
-
withPassword
Set the password property: Password of admin account.- Parameters:
password- the password value to set.- Returns:
- the VirtualMachineSshCredentials object itself.
-
publicKeyData
Get the publicKeyData property: Public key data.- Returns:
- the publicKeyData value.
-
withPublicKeyData
Set the publicKeyData property: Public key data.- Parameters:
publicKeyData- the publicKeyData value to set.- Returns:
- the VirtualMachineSshCredentials object itself.
-
privateKeyData
Get the privateKeyData property: Private key data.- Returns:
- the privateKeyData value.
-
withPrivateKeyData
Set the privateKeyData property: Private key data.- Parameters:
privateKeyData- the privateKeyData value to set.- Returns:
- the VirtualMachineSshCredentials 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<VirtualMachineSshCredentials>- Throws:
IOException
-
fromJson
public static VirtualMachineSshCredentials fromJson(com.azure.json.JsonReader jsonReader) throws IOException Reads an instance of VirtualMachineSshCredentials from the JsonReader.- Parameters:
jsonReader- The JsonReader being read.- Returns:
- An instance of VirtualMachineSshCredentials if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.
- Throws:
IOException- If an error occurs while reading the VirtualMachineSshCredentials.
-