Class RunCommandRequest
java.lang.Object
com.azure.resourcemanager.containerservice.models.RunCommandRequest
- All Implemented Interfaces:
com.azure.json.JsonSerializable<RunCommandRequest>
public final class RunCommandRequest
extends Object
implements com.azure.json.JsonSerializable<RunCommandRequest>
A run command request.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGet the clusterToken property: AuthToken issued for AKS AAD Server App.command()Get the command property: The command to run.context()Get the context property: A base64 encoded zip file containing the files required by the command.static RunCommandRequestfromJson(com.azure.json.JsonReader jsonReader) Reads an instance of RunCommandRequest from the JsonReader.com.azure.json.JsonWritertoJson(com.azure.json.JsonWriter jsonWriter) voidvalidate()Validates the instance.withClusterToken(String clusterToken) Set the clusterToken property: AuthToken issued for AKS AAD Server App.withCommand(String command) Set the command property: The command to run.withContext(String context) Set the context property: A base64 encoded zip file containing the files required by the command.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
-
RunCommandRequest
public RunCommandRequest()Creates an instance of RunCommandRequest class.
-
-
Method Details
-
command
Get the command property: The command to run.- Returns:
- the command value.
-
withCommand
Set the command property: The command to run.- Parameters:
command- the command value to set.- Returns:
- the RunCommandRequest object itself.
-
context
Get the context property: A base64 encoded zip file containing the files required by the command.- Returns:
- the context value.
-
withContext
Set the context property: A base64 encoded zip file containing the files required by the command.- Parameters:
context- the context value to set.- Returns:
- the RunCommandRequest object itself.
-
clusterToken
Get the clusterToken property: AuthToken issued for AKS AAD Server App.- Returns:
- the clusterToken value.
-
withClusterToken
Set the clusterToken property: AuthToken issued for AKS AAD Server App.- Parameters:
clusterToken- the clusterToken value to set.- Returns:
- the RunCommandRequest 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<RunCommandRequest>- Throws:
IOException
-
fromJson
Reads an instance of RunCommandRequest from the JsonReader.- Parameters:
jsonReader- The JsonReader being read.- Returns:
- An instance of RunCommandRequest 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 RunCommandRequest.
-