- All Implemented Interfaces:
com.azure.json.JsonSerializable<ApprovalStage>
public final class ApprovalStage
extends Object
implements com.azure.json.JsonSerializable<ApprovalStage>
The approval stage.
-
Constructor Summary
Constructors
Creates an instance of ApprovalStage class.
-
Method Summary
Get the approvalStageTimeOutInDays property: The time in days when approval request would be timed out.
Get the escalationApprovers property: The escalation approver of the request.
Get the escalationTimeInMinutes property: The time in minutes when the approval request would be escalated if the
primary approver does not approve.
fromJson(com.azure.json.JsonReader jsonReader)
Reads an instance of ApprovalStage from the JsonReader.
Get the isApproverJustificationRequired property: Determines whether approver need to provide justification for
his decision.
Get the isEscalationEnabled property: The value determine whether escalation feature is enabled.
Get the primaryApprovers property: The primary approver of the request.
com.azure.json.JsonWriter
toJson(com.azure.json.JsonWriter jsonWriter)
void
Set the approvalStageTimeOutInDays property: The time in days when approval request would be timed out.
Set the escalationApprovers property: The escalation approver of the request.
Set the escalationTimeInMinutes property: The time in minutes when the approval request would be escalated if the
primary approver does not approve.
Set the isApproverJustificationRequired property: Determines whether approver need to provide justification for
his decision.
Set the isEscalationEnabled property: The value determine whether escalation feature is enabled.
Set the primaryApprovers property: The primary approver of the request.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.azure.json.JsonSerializable
toJson, toJson, toJsonBytes, toJsonString
-
Constructor Details
-
ApprovalStage
public ApprovalStage()
Creates an instance of ApprovalStage class.
-
Method Details
-
approvalStageTimeOutInDays
public Integer approvalStageTimeOutInDays()
Get the approvalStageTimeOutInDays property: The time in days when approval request would be timed out.
- Returns:
- the approvalStageTimeOutInDays value.
-
withApprovalStageTimeOutInDays
Set the approvalStageTimeOutInDays property: The time in days when approval request would be timed out.
- Parameters:
approvalStageTimeOutInDays - the approvalStageTimeOutInDays value to set.
- Returns:
- the ApprovalStage object itself.
-
isApproverJustificationRequired
public Boolean isApproverJustificationRequired()
Get the isApproverJustificationRequired property: Determines whether approver need to provide justification for
his decision.
- Returns:
- the isApproverJustificationRequired value.
-
withIsApproverJustificationRequired
Set the isApproverJustificationRequired property: Determines whether approver need to provide justification for
his decision.
- Parameters:
isApproverJustificationRequired - the isApproverJustificationRequired value to set.
- Returns:
- the ApprovalStage object itself.
-
escalationTimeInMinutes
public Integer escalationTimeInMinutes()
Get the escalationTimeInMinutes property: The time in minutes when the approval request would be escalated if the
primary approver does not approve.
- Returns:
- the escalationTimeInMinutes value.
-
withEscalationTimeInMinutes
Set the escalationTimeInMinutes property: The time in minutes when the approval request would be escalated if the
primary approver does not approve.
- Parameters:
escalationTimeInMinutes - the escalationTimeInMinutes value to set.
- Returns:
- the ApprovalStage object itself.
-
primaryApprovers
Get the primaryApprovers property: The primary approver of the request.
- Returns:
- the primaryApprovers value.
-
withPrimaryApprovers
Set the primaryApprovers property: The primary approver of the request.
- Parameters:
primaryApprovers - the primaryApprovers value to set.
- Returns:
- the ApprovalStage object itself.
-
isEscalationEnabled
public Boolean isEscalationEnabled()
Get the isEscalationEnabled property: The value determine whether escalation feature is enabled.
- Returns:
- the isEscalationEnabled value.
-
withIsEscalationEnabled
Set the isEscalationEnabled property: The value determine whether escalation feature is enabled.
- Parameters:
isEscalationEnabled - the isEscalationEnabled value to set.
- Returns:
- the ApprovalStage object itself.
-
escalationApprovers
Get the escalationApprovers property: The escalation approver of the request.
- Returns:
- the escalationApprovers value.
-
withEscalationApprovers
Set the escalationApprovers property: The escalation approver of the request.
- Parameters:
escalationApprovers - the escalationApprovers value to set.
- Returns:
- the ApprovalStage object itself.
-
validate
public void validate()
Validates the instance.
- Throws:
IllegalArgumentException - thrown if the instance is not valid.
-
toJson
public com.azure.json.JsonWriter toJson(com.azure.json.JsonWriter jsonWriter)
throws IOException
- Specified by:
toJson in interface com.azure.json.JsonSerializable<ApprovalStage>
- Throws:
IOException
-
fromJson
Reads an instance of ApprovalStage from the JsonReader.
- Parameters:
jsonReader - The JsonReader being read.
- Returns:
- An instance of ApprovalStage 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 ApprovalStage.