Top Description Methods
net.sf.ehcache.search.impl

public Interface SearchManager

Known Direct Implementers
net.sf.ehcache.store.BruteForceSearchManager
Imports
java.util.Map, .Set, net.sf.ehcache.Element, net.sf.ehcache.search.Attribute, .Results, net.sf.ehcache.search.attribute.AttributeExtractor, .DynamicAttributesExtractor, net.sf.ehcache.store.StoreQuery

Interface for ehcache search engine implementations
Author
teck

Method Summary

Modifier and TypeMethod and Description
public void
clear(String
cache name to clear
cacheName
,
int
segment of cache
segmentId
)

Clear a segment of the given cache

public Results

Returns:

search results
executeQuery
(StoreQuery
query to execute
query
,
Map<String, AttributeExtractor>
defined attribute extractors for the cache
attributeExtractors
,
DynamicAttributesExtractor
dynamic attribute extractor (if any)
dynamicIndexer
)

Execute a query against the given cache

public Set<Attribute<T>>
getSearchAttributes(String cacheName)

Returns all known search attributes for cache with given name

public void
put(String
cache name
cacheName
,
int
segment of cache
segmentId
,
Element
element being added to cache
element
,
byte[]
serialized form of the element key
serializedKey
,
Map<String, AttributeExtractor>
the attribute extractors for the cache
extractors
,
DynamicAttributesExtractor
dynamic attribute extractor (if any)
dynamicIndexer
)

Notify an element added to a segment of a given cache

public void
remove(String
cache name
cacheName
,
Object
unique key of element
uniqueKey
,
int
segment of cache
segmentId
,
boolean
true if called as a result of actual storage engine removal (as opposed to move), false otherwise
isRemoval
)

Notify an element removed from a segment of a given cache

Method Detail

clearback to summary
public void clear(String cacheName, int segmentId)

Clear a segment of the given cache

Parameters
cacheName:String

cache name to clear

segmentId:int

segment of cache

executeQueryback to summary
public Results executeQuery(StoreQuery query, Map<String, AttributeExtractor> attributeExtractors, DynamicAttributesExtractor dynamicIndexer)

Execute a query against the given cache

Parameters
query:StoreQuery

query to execute

attributeExtractors:Map<String, AttributeExtractor>

defined attribute extractors for the cache

dynamicIndexer:DynamicAttributesExtractor

dynamic attribute extractor (if any)

Returns:Results

search results

getSearchAttributesback to summary
public Set<Attribute<T>> getSearchAttributes(String cacheName)

Returns all known search attributes for cache with given name

putback to summary
public void put(String cacheName, int segmentId, Element element, byte[] serializedKey, Map<String, AttributeExtractor> extractors, DynamicAttributesExtractor dynamicIndexer)

Notify an element added to a segment of a given cache

Parameters
cacheName:String

cache name

segmentId:int

segment of cache

element:Element

element being added to cache

serializedKey:byte[]

serialized form of the element key

extractors:Map<String, AttributeExtractor>

the attribute extractors for the cache

dynamicIndexer:DynamicAttributesExtractor

dynamic attribute extractor (if any)

removeback to summary
public void remove(String cacheName, Object uniqueKey, int segmentId, boolean isRemoval)

Notify an element removed from a segment of a given cache

Parameters
cacheName:String

cache name

uniqueKey:Object

unique key of element

segmentId:int

segment of cache

isRemoval:boolean

true if called as a result of actual storage engine removal (as opposed to move), false otherwise