org.hibernate.search.indexes.spi

## Interface IndexManagerSelector

- All Known Implementing Classes:
    IndexShardingStrategyIndexManagerSelector, NotShardedIndexManagerSelector

      public interface IndexManagerSelector

  Author:
    Yoann Rodiere

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `Set<IndexManager>` | `all()` Ask for all shards (eg to optimize)
    `Set<IndexManager>` | `forExisting(IndexedTypeIdentifier typeId, Serializable id, String idInString)`
    `Set<IndexManager>` | `forFilters(FullTextFilterImplementor[] fullTextFilters)`
    `IndexManager` | `forNew(IndexedTypeIdentifier typeId, Serializable id, String idInString, Document document)`

- - ### Method Detail

    - #### all

          Set<IndexManager> all()

      Ask for all shards (eg to optimize)
      Returns:
        all the `IndexManager` for all shards

    - #### forNew

          IndexManager forNew(IndexedTypeIdentifier typeId,
                              Serializable id,
                              String idInString,
                              Document document)

      Parameters:
        `typeId` - the type of the entity
        `id` - the id in object form
        `idInString` - the id as transformed by the used TwoWayStringBridge
        `document` - the document to index
      Returns:
        the IndexManager where the given entity will be indexed

    - #### forExisting

          Set<IndexManager> forExisting(IndexedTypeIdentifier typeId,
                                        Serializable id,
                                        String idInString)

      Parameters:
        `typeId` - the type of the existing entity
        `id` - the id in object form
        `idInString` - the id as transformed by the used TwoWayStringBridge
      Returns:
        If id and idInString are non-null, the `IndexManager`(s) where the given entity is stored. If they are null, all the `IndexManager`(s) where an entity of the given type is stored.

    - #### forFilters

          Set<IndexManager> forFilters(FullTextFilterImplementor[] fullTextFilters)

      Parameters:
        `fullTextFilters` - the filters applied to the query; must be empty if no filter is applied
      Returns:
        the set of `IndexManager`(s) where the entities matching the filters are stored

Copyright © 2006-2017 Red Hat, Inc. All Rights Reserved