Class AuthCredential
java.lang.Object
com.azure.resourcemanager.containerregistry.models.AuthCredential
- All Implemented Interfaces:
com.azure.json.JsonSerializable<AuthCredential>
public final class AuthCredential
extends Object
implements com.azure.json.JsonSerializable<AuthCredential>
Authentication credential stored for an upstream.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGet the credentialHealth property: This provides data pertaining to the health of the auth credential.static AuthCredentialfromJson(com.azure.json.JsonReader jsonReader) Reads an instance of AuthCredential from the JsonReader.name()Get the name property: The name of the credential.Get the passwordSecretIdentifier property: KeyVault Secret URI for accessing the password.com.azure.json.JsonWritertoJson(com.azure.json.JsonWriter jsonWriter) Get the usernameSecretIdentifier property: KeyVault Secret URI for accessing the username.voidvalidate()Validates the instance.withName(CredentialName name) Set the name property: The name of the credential.withPasswordSecretIdentifier(String passwordSecretIdentifier) Set the passwordSecretIdentifier property: KeyVault Secret URI for accessing the password.withUsernameSecretIdentifier(String usernameSecretIdentifier) Set the usernameSecretIdentifier property: KeyVault Secret URI for accessing the username.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
-
AuthCredential
public AuthCredential()Creates an instance of AuthCredential class.
-
-
Method Details
-
name
Get the name property: The name of the credential.- Returns:
- the name value.
-
withName
Set the name property: The name of the credential.- Parameters:
name- the name value to set.- Returns:
- the AuthCredential object itself.
-
usernameSecretIdentifier
Get the usernameSecretIdentifier property: KeyVault Secret URI for accessing the username.- Returns:
- the usernameSecretIdentifier value.
-
withUsernameSecretIdentifier
Set the usernameSecretIdentifier property: KeyVault Secret URI for accessing the username.- Parameters:
usernameSecretIdentifier- the usernameSecretIdentifier value to set.- Returns:
- the AuthCredential object itself.
-
passwordSecretIdentifier
Get the passwordSecretIdentifier property: KeyVault Secret URI for accessing the password.- Returns:
- the passwordSecretIdentifier value.
-
withPasswordSecretIdentifier
Set the passwordSecretIdentifier property: KeyVault Secret URI for accessing the password.- Parameters:
passwordSecretIdentifier- the passwordSecretIdentifier value to set.- Returns:
- the AuthCredential object itself.
-
credentialHealth
Get the credentialHealth property: This provides data pertaining to the health of the auth credential.- Returns:
- the credentialHealth value.
-
validate
public void validate()Validates the instance.- Throws:
IllegalArgumentException- thrown if the instance is not valid.
-
toJson
- Specified by:
toJsonin interfacecom.azure.json.JsonSerializable<AuthCredential>- Throws:
IOException
-
fromJson
Reads an instance of AuthCredential from the JsonReader.- Parameters:
jsonReader- The JsonReader being read.- Returns:
- An instance of AuthCredential 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 AuthCredential.
-