Class PerAgentTokenHibernateDao

java.lang.Object
org.springframework.dao.support.DaoSupport
org.springframework.orm.hibernate5.support.HibernateDaoSupport
All Implemented Interfaces:
PerAgentTokenDao, BambooObjectDao<PerAgentToken>, org.springframework.beans.factory.InitializingBean

public class PerAgentTokenHibernateDao extends BambooHibernateObjectDao<PerAgentToken> implements PerAgentTokenDao
  • Constructor Details

    • PerAgentTokenHibernateDao

      public PerAgentTokenHibernateDao()
  • Method Details

    • save

      public void save(@NotNull @NotNull String resultKey, @NotNull @NotNull String token)
      Description copied from interface: PerAgentTokenDao
      Saves token for a given result key.
      Specified by:
      save in interface PerAgentTokenDao
      Parameters:
      resultKey - result key
      token - token
    • isValid

      public boolean isValid(@NotNull @NotNull String resultKey, @NotNull @NotNull String token)
      Description copied from interface: PerAgentTokenDao
      Checks if token is valid for a given result key.
      Specified by:
      isValid in interface PerAgentTokenDao
      Parameters:
      resultKey - result key
      token - token
      Returns:
      true if token is valid, false otherwise
    • isValidForAnyResultKey

      public boolean isValidForAnyResultKey(@NotNull @NotNull String token)
      Description copied from interface: PerAgentTokenDao
      Checks if token is valid for any result key.
      Specified by:
      isValidForAnyResultKey in interface PerAgentTokenDao
      Parameters:
      token - token
      Returns:
      true if token is valid, false otherwise
    • delete

      public void delete(@NotNull @NotNull String resultKey, @NotNull @NotNull Timestamp dueTimestamp)
      Description copied from interface: PerAgentTokenDao
      Deletes all tokens for a given result key created before the passed timestamp.
      Specified by:
      delete in interface PerAgentTokenDao
      Parameters:
      resultKey - result key
      dueTimestamp - due timestamp