org.apache.cassandra.index.sasi.utils.trie

## Interface Cursor<K,V>

-     public interface Cursor<K,V>

  A `Cursor` can be used to traverse a `Trie`, visit each node step by step and make `Cursor.Decision`s on each step how to continue with traversing the `Trie`.

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Interface and Description
    --- | ---
    `static class` | `Cursor.Decision` The `Cursor.Decision` tells the `Cursor` what to do on each step while traversing the `Trie`.

  - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `Cursor.Decision` | `select(java.util.Map.Entry<? extends K,? extends V> entry)` Called for each `Map.Entry` in the `Trie`.

- - ### Method Detail

    - #### select

          Cursor.Decision select(java.util.Map.Entry<? extends K,? extends V> entry)

      Called for each `Map.Entry` in the `Trie`. Return `Cursor.Decision.EXIT` to finish the `Trie` operation, `Cursor.Decision.CONTINUE` to go to the next `Map.Entry`, `Cursor.Decision.REMOVE` to remove the `Map.Entry` and continue iterating or `Cursor.Decision.REMOVE_AND_EXIT` to remove the `Map.Entry` and stop iterating. Note: Not all operations support `Cursor.Decision.REMOVE`.

Copyright © 2018 The Apache Software Foundation