Class ApiToken

java.lang.Object
org.genesys.blocks.model.EmptyModel
org.genesys.blocks.model.BasicModel
org.genesys.blocks.model.VersionedModel
org.genesys.blocks.model.AuditedVersionedModel
org.genesys.blocks.tokenauth.model.ApiToken
All Implemented Interfaces:
Serializable, org.genesys.blocks.model.Activatable, org.genesys.blocks.model.Copyable<ApiToken>, org.genesys.blocks.model.EntityId, org.springframework.data.domain.Persistable<Long>

@Entity public class ApiToken extends AuditedVersionedModel implements org.genesys.blocks.model.Copyable<ApiToken>
ApiToken supports token-based authentication. Each token is unique in the system and links to one and only one AclSid.
See Also:
  • Field Summary

    Fields inherited from class org.genesys.blocks.model.VersionedModel

    active

    Fields inherited from interface org.genesys.blocks.model.Copyable

    COPYABLE_FIELDS
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
     
    boolean
    Check if token is not expired.

    Methods inherited from class org.genesys.blocks.model.VersionedModel

    getVersion, isActive, setActive, setVersion, toString

    Methods inherited from class org.genesys.blocks.model.BasicModel

    getId, setId

    Methods inherited from class org.genesys.blocks.model.EmptyModel

    equals, hashCode, isNew

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait

    Methods inherited from interface org.genesys.blocks.model.Copyable

    apply, copy, copyList
  • Constructor Details

    • ApiToken

      public ApiToken()
  • Method Details

    • canEqual

      public boolean canEqual(Object other)
      Specified by:
      canEqual in class org.genesys.blocks.model.EmptyModel
    • isCredentialsNonExpired

      public boolean isCredentialsNonExpired()
      Check if token is not expired. API Token is non-expired when expires is null or is in the future. Token is expired if expires if non-null and it is in the past.
      Returns:
      true if expired.