Class ClusterCommandExecutor.NodeResult<T>

java.lang.Object
org.springframework.data.redis.connection.ClusterCommandExecutor.NodeResult<T>
Type Parameters:
T - Type of the value returned in the result.
Enclosing class:
ClusterCommandExecutor

public static class ClusterCommandExecutor.NodeResult<T> extends Object
Since:
1.7
Author:
Christoph Strobl, John Blum
  • Constructor Details

  • Method Details

    • getNode

      public RedisClusterNode getNode()
      Get the RedisClusterNode the command was executed on.
      Returns:
      never null.
    • getKey

      public byte[] getKey()
      Return the key mapped to the value stored in Redis.
      Returns:
      a byte array of the key mapped to the value stored in Redis.
    • getValue

      @Nullable public T getValue()
      Get the actual value of the command execution.
      Returns:
      can be null.
    • mapValue

      @Nullable public <U> U mapValue(Function<? super T,? extends U> mapper)
      Apply the mapper function to the value and return the mapped value.
      Type Parameters:
      U - type of the mapped value.
      Parameters:
      mapper - must not be null.
      Returns:
      the mapped value.
      Since:
      2.1
    • equals

      public boolean equals(@Nullable Object obj)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object