Class AbstractValueDao

java.lang.Object
top.codef.redisdao.AbstractRedisDDao
top.codef.redisdao.AbstractValueDao
All Implemented Interfaces:
RedisDao, RedisDDao

public abstract class AbstractValueDao extends AbstractRedisDDao
  • Constructor Details

    • AbstractValueDao

      public AbstractValueDao()
  • Method Details

    • createValueOperation

      protected org.springframework.data.redis.core.ValueOperations<String,String> createValueOperation()
      Returns:
    • set

      public void set(String key, String value, int time, TimeUnit unit)
      Parameters:
      key -
      value -
      time -
      unit -
    • set

      public void set(String key, String value, Duration time)
      Parameters:
      key -
      value -
      time -
    • set

      public void set(String key, String value)
      Parameters:
      key -
      value -
    • setIfAbsent

      public Boolean setIfAbsent(String key, String value)
      Parameters:
      key -
      value -
      Returns:
    • setIfAbsent

      public Boolean setIfAbsent(String key, String value, Duration duration)
      Parameters:
      key -
      value -
      duration -
      Returns:
    • get

      public String get(String key)
      Parameters:
      key -
      Returns:
    • getExpire

      public long getExpire(String key, TimeUnit unit)
      Parameters:
      key -
      unit -
      Returns: