org.modeshape.jcr.spi.index.provider

## Interface ManagedIndex

- All Superinterfaces:
    Costable, Filter
  All Known Implementing Classes:
    ManagedLocalIndex

      public interface ManagedIndex
      extends Filter, Costable

  The top-level interface for an index owned by a provider, with common methods needed by indexes regardless of number of columns.

- - ### Nested Class Summary

    - ### Nested classes/interfaces inherited from interface org.modeshape.jcr.spi.index.provider.Filter

      `Filter.Results`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `enable(boolean enable)` Mark whether this index is enabled for use, or not enabled meaning it should not be used.
    `IndexChangeAdapter` | `getIndexChangeAdapter()` Get the ChangeSetAdapter implementation through which changes to content are sent to the index.
    `boolean` | `isEnabled()` Determine if this index is enabled for use.
    `void` | `removeAll()` Remove all of the index entries from the index.
    `void` | `shutdown(boolean destroyed)` Shut down this index and release all runtime resources.

    - ### Methods inherited from interface org.modeshape.jcr.spi.index.provider.Filter

      `filter`

    - ### Methods inherited from interface org.modeshape.jcr.spi.index.provider.Costable

      `estimateCardinality, estimateTotalCount`

- - ### Method Detail

    - #### getIndexChangeAdapter

          IndexChangeAdapter getIndexChangeAdapter()

      Get the ChangeSetAdapter implementation through which changes to content are sent to the index. Each local index has an `ChangeSetListener` that is registered on the event bus and kept throughout the lifetime of the index (even if there are changes), and that listener delegates to this adapter.
      Returns:
        the adapter; never null

    - #### removeAll

          void removeAll()

      Remove all of the index entries from the index. This is typically called prior to reindexing.

    - #### shutdown

          void shutdown(boolean destroyed)

      Shut down this index and release all runtime resources. If `destroyed` is `true`, then this index has been removed from the repository and will not be reused; thus all persistent resources should also be released. If `destroyed` is `false`, then this repository is merely shutting down and the index's persistent resources should be kept so that they are available when the repository is restarted.
      Parameters:
        `destroyed` - true if this index is being permanently removed from the repository and all runtime and persistent resources can/should be released and cleaned up, or false if the repository is being shutdown and this index will be needed the next time the repository is started

    - #### enable

          void enable(boolean enable)

      Mark whether this index is enabled for use, or not enabled meaning it should not be used.
      Parameters:
        `enable` - true if the index is to be enabled, or false otherwise

    - #### isEnabled

          boolean isEnabled()

      Determine if this index is enabled for use.
      Returns:
        true if enabled, or false otherwise

Copyright © 2008-2014 JBoss, a division of Red Hat. All Rights Reserved.