Interface KeyIterator

All Known Implementing Classes:
KeyIteratorImpl

@Deprecated public interface KeyIterator
Deprecated.
memcached 1.6.x will remove cachedump stats command,so this feature will be removed in the future
Key Iterator for memcached,use 'stats items' and 'stats cachedump' to iterate all keys,it is inefficient and not thread-safe.The 'stats cachedump" has length limitation,then iterator could not visit all keys if you have many keys.

Note: memcached 1.6.x will remove cachedump stats,so this feature will be invalid in memcached 1.6.x

  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Deprecated.
    Close this iterator when you don't need it any more.It is not mandatory to call this method, but you might want to invoke this method for maximum performance.
    Deprecated.
    Get current iterator's memcached server address
    boolean
    Deprecated.
    Check if the iterator has more keys.
    Deprecated.
    Get next key,if iterator has reached the end,throw ArrayIndexOutOfBoundsException
    void
    setOpTimeout(long opTimeout)
    Deprecated.
    Set operation timeout,default is 1000 MILLISECONDS.
  • Method Details

    • next

      Deprecated.
      Get next key,if iterator has reached the end,throw ArrayIndexOutOfBoundsException
      Returns:
      Throws:
      ArrayIndexOutOfBoundsException - ,MemcachedException,TimeoutException,InterruptedException
      MemcachedException
      TimeoutException
      InterruptedException
    • hasNext

      boolean hasNext()
      Deprecated.
      Check if the iterator has more keys.
      Returns:
    • close

      void close()
      Deprecated.
      Close this iterator when you don't need it any more.It is not mandatory to call this method, but you might want to invoke this method for maximum performance.
    • getServerAddress

      InetSocketAddress getServerAddress()
      Deprecated.
      Get current iterator's memcached server address
      Returns:
    • setOpTimeout

      void setOpTimeout(long opTimeout)
      Deprecated.
      Set operation timeout,default is 1000 MILLISECONDS.
      Parameters:
      opTimeout -