Class TaskRunRequest
java.lang.Object
com.azure.resourcemanager.containerregistry.models.RunRequest
com.azure.resourcemanager.containerregistry.models.TaskRunRequest
- All Implemented Interfaces:
com.azure.json.JsonSerializable<RunRequest>
The parameters for a task run request.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic TaskRunRequestfromJson(com.azure.json.JsonReader jsonReader) Reads an instance of TaskRunRequest from the JsonReader.Get the overrideTaskStepProperties property: Set of overridable parameters that can be passed when running a Task.taskId()Get the taskId property: The resource ID of task against which run has to be queued.com.azure.json.JsonWritertoJson(com.azure.json.JsonWriter jsonWriter) type()Get the type property: The type of the run request.voidvalidate()Validates the instance.withAgentPoolName(String agentPoolName) Set the agentPoolName property: The dedicated agent pool for the run.withIsArchiveEnabled(Boolean isArchiveEnabled) Set the isArchiveEnabled property: The value that indicates whether archiving is enabled for the run or not.withLogTemplate(String logTemplate) Set the logTemplate property: The template that describes the repository and tag information for run log artifact.withOverrideTaskStepProperties(OverrideTaskStepProperties overrideTaskStepProperties) Set the overrideTaskStepProperties property: Set of overridable parameters that can be passed when running a Task.withTaskId(String taskId) Set the taskId property: The resource ID of task against which run has to be queued.Methods inherited from class com.azure.resourcemanager.containerregistry.models.RunRequest
agentPoolName, isArchiveEnabled, logTemplateMethods 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
-
TaskRunRequest
public TaskRunRequest()Creates an instance of TaskRunRequest class.
-
-
Method Details
-
type
Get the type property: The type of the run request.- Overrides:
typein classRunRequest- Returns:
- the type value.
-
taskId
Get the taskId property: The resource ID of task against which run has to be queued.- Returns:
- the taskId value.
-
withTaskId
Set the taskId property: The resource ID of task against which run has to be queued.- Parameters:
taskId- the taskId value to set.- Returns:
- the TaskRunRequest object itself.
-
overrideTaskStepProperties
Get the overrideTaskStepProperties property: Set of overridable parameters that can be passed when running a Task.- Returns:
- the overrideTaskStepProperties value.
-
withOverrideTaskStepProperties
public TaskRunRequest withOverrideTaskStepProperties(OverrideTaskStepProperties overrideTaskStepProperties) Set the overrideTaskStepProperties property: Set of overridable parameters that can be passed when running a Task.- Parameters:
overrideTaskStepProperties- the overrideTaskStepProperties value to set.- Returns:
- the TaskRunRequest object itself.
-
withIsArchiveEnabled
Set the isArchiveEnabled property: The value that indicates whether archiving is enabled for the run or not.- Overrides:
withIsArchiveEnabledin classRunRequest- Parameters:
isArchiveEnabled- the isArchiveEnabled value to set.- Returns:
- the RunRequest object itself.
-
withAgentPoolName
Set the agentPoolName property: The dedicated agent pool for the run.- Overrides:
withAgentPoolNamein classRunRequest- Parameters:
agentPoolName- the agentPoolName value to set.- Returns:
- the RunRequest object itself.
-
withLogTemplate
Set the logTemplate property: The template that describes the repository and tag information for run log artifact.- Overrides:
withLogTemplatein classRunRequest- Parameters:
logTemplate- the logTemplate value to set.- Returns:
- the RunRequest object itself.
-
validate
public void validate()Validates the instance.- Overrides:
validatein classRunRequest- Throws:
IllegalArgumentException- thrown if the instance is not valid.
-
toJson
- Specified by:
toJsonin interfacecom.azure.json.JsonSerializable<RunRequest>- Overrides:
toJsonin classRunRequest- Throws:
IOException
-
fromJson
Reads an instance of TaskRunRequest from the JsonReader.- Parameters:
jsonReader- The JsonReader being read.- Returns:
- An instance of TaskRunRequest 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 TaskRunRequest.
-