Class LeaseContainerRequest
- java.lang.Object
-
- com.azure.resourcemanager.storage.models.LeaseContainerRequest
-
public final class LeaseContainerRequest extends Object
Lease Container request schema.
-
-
Constructor Summary
Constructors Constructor Description LeaseContainerRequest()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description LeaseContainerRequestActionaction()Get the action property: Specifies the lease action.IntegerbreakPeriod()Get the breakPeriod property: Optional.IntegerleaseDuration()Get the leaseDuration property: Required for acquire.StringleaseId()Get the leaseId property: Identifies the lease.StringproposedLeaseId()Get the proposedLeaseId property: Optional for acquire, required for change.voidvalidate()Validates the instance.LeaseContainerRequestwithAction(LeaseContainerRequestAction action)Set the action property: Specifies the lease action.LeaseContainerRequestwithBreakPeriod(Integer breakPeriod)Set the breakPeriod property: Optional.LeaseContainerRequestwithLeaseDuration(Integer leaseDuration)Set the leaseDuration property: Required for acquire.LeaseContainerRequestwithLeaseId(String leaseId)Set the leaseId property: Identifies the lease.LeaseContainerRequestwithProposedLeaseId(String proposedLeaseId)Set the proposedLeaseId property: Optional for acquire, required for change.
-
-
-
Method Detail
-
action
public LeaseContainerRequestAction action()
Get the action property: Specifies the lease action. Can be one of the available actions.- Returns:
- the action value.
-
withAction
public LeaseContainerRequest withAction(LeaseContainerRequestAction action)
Set the action property: Specifies the lease action. Can be one of the available actions.- Parameters:
action- the action value to set.- Returns:
- the LeaseContainerRequest object itself.
-
leaseId
public String leaseId()
Get the leaseId property: Identifies the lease. Can be specified in any valid GUID string format.- Returns:
- the leaseId value.
-
withLeaseId
public LeaseContainerRequest withLeaseId(String leaseId)
Set the leaseId property: Identifies the lease. Can be specified in any valid GUID string format.- Parameters:
leaseId- the leaseId value to set.- Returns:
- the LeaseContainerRequest object itself.
-
breakPeriod
public Integer breakPeriod()
Get the breakPeriod property: Optional. For a break action, proposed duration the lease should continue before it is broken, in seconds, between 0 and 60.- Returns:
- the breakPeriod value.
-
withBreakPeriod
public LeaseContainerRequest withBreakPeriod(Integer breakPeriod)
Set the breakPeriod property: Optional. For a break action, proposed duration the lease should continue before it is broken, in seconds, between 0 and 60.- Parameters:
breakPeriod- the breakPeriod value to set.- Returns:
- the LeaseContainerRequest object itself.
-
leaseDuration
public Integer leaseDuration()
Get the leaseDuration property: Required for acquire. Specifies the duration of the lease, in seconds, or negative one (-1) for a lease that never expires.- Returns:
- the leaseDuration value.
-
withLeaseDuration
public LeaseContainerRequest withLeaseDuration(Integer leaseDuration)
Set the leaseDuration property: Required for acquire. Specifies the duration of the lease, in seconds, or negative one (-1) for a lease that never expires.- Parameters:
leaseDuration- the leaseDuration value to set.- Returns:
- the LeaseContainerRequest object itself.
-
proposedLeaseId
public String proposedLeaseId()
Get the proposedLeaseId property: Optional for acquire, required for change. Proposed lease ID, in a GUID string format.- Returns:
- the proposedLeaseId value.
-
withProposedLeaseId
public LeaseContainerRequest withProposedLeaseId(String proposedLeaseId)
Set the proposedLeaseId property: Optional for acquire, required for change. Proposed lease ID, in a GUID string format.- Parameters:
proposedLeaseId- the proposedLeaseId value to set.- Returns:
- the LeaseContainerRequest object itself.
-
validate
public void validate()
Validates the instance.- Throws:
IllegalArgumentException- thrown if the instance is not valid.
-
-