Class V1LeaseSpec
java.lang.Object
io.kubernetes.client.openapi.models.V1LeaseSpec
@Generated(value="org.openapitools.codegen.languages.JavaClientCodegen",
date="2024-04-23T13:45:09.091597Z[Etc/UTC]")
public class V1LeaseSpec
extends Object
LeaseSpec is a specification of a Lease.
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionacquireTime
(OffsetDateTime acquireTime) boolean
static V1LeaseSpec
Create an instance of V1LeaseSpec given an JSON stringacquireTime is a time when the current lease was acquired.holderIdentity contains the identity of the holder of a current lease.leaseDurationSeconds is a duration that candidates for a lease need to wait to force acquire it.leaseTransitions is the number of transitions of a lease between holders.renewTime is a time when the current holder of a lease has last updated the lease.int
hashCode()
holderIdentity
(String holderIdentity) leaseDurationSeconds
(Integer leaseDurationSeconds) leaseTransitions
(Integer leaseTransitions) renewTime
(OffsetDateTime renewTime) void
setAcquireTime
(OffsetDateTime acquireTime) void
setHolderIdentity
(String holderIdentity) void
setLeaseDurationSeconds
(Integer leaseDurationSeconds) void
setLeaseTransitions
(Integer leaseTransitions) void
setRenewTime
(OffsetDateTime renewTime) toJson()
Convert an instance of V1LeaseSpec to an JSON stringtoString()
static void
validateJsonObject
(com.google.gson.JsonObject jsonObj) Validates the JSON Object and throws an exception if issues found
-
Field Details
-
SERIALIZED_NAME_ACQUIRE_TIME
- See Also:
-
SERIALIZED_NAME_HOLDER_IDENTITY
- See Also:
-
SERIALIZED_NAME_LEASE_DURATION_SECONDS
- See Also:
-
SERIALIZED_NAME_LEASE_TRANSITIONS
- See Also:
-
SERIALIZED_NAME_RENEW_TIME
- See Also:
-
openapiFields
-
openapiRequiredFields
-
-
Constructor Details
-
V1LeaseSpec
public V1LeaseSpec()
-
-
Method Details
-
acquireTime
-
getAcquireTime
acquireTime is a time when the current lease was acquired.- Returns:
- acquireTime
-
setAcquireTime
-
holderIdentity
-
getHolderIdentity
holderIdentity contains the identity of the holder of a current lease.- Returns:
- holderIdentity
-
setHolderIdentity
-
leaseDurationSeconds
-
getLeaseDurationSeconds
leaseDurationSeconds is a duration that candidates for a lease need to wait to force acquire it. This is measure against time of last observed renewTime.- Returns:
- leaseDurationSeconds
-
setLeaseDurationSeconds
-
leaseTransitions
-
getLeaseTransitions
leaseTransitions is the number of transitions of a lease between holders.- Returns:
- leaseTransitions
-
setLeaseTransitions
-
renewTime
-
getRenewTime
renewTime is a time when the current holder of a lease has last updated the lease.- Returns:
- renewTime
-
setRenewTime
-
equals
-
hashCode
public int hashCode() -
toString
-
validateJsonObject
Validates the JSON Object and throws an exception if issues found- Parameters:
jsonObj
- JSON Object- Throws:
IOException
- if the JSON Object is invalid with respect to V1LeaseSpec
-
fromJson
Create an instance of V1LeaseSpec given an JSON string- Parameters:
jsonString
- JSON string- Returns:
- An instance of V1LeaseSpec
- Throws:
IOException
- if the JSON string is invalid with respect to V1LeaseSpec
-
toJson
Convert an instance of V1LeaseSpec to an JSON string- Returns:
- JSON string
-