| com.jofti.core.InternalIndex
All known Subclasses: com.jofti.tree.TreeIndex,
InternalIndex | public interface InternalIndex (Code) | | The Internal IndexCache is the core interface that IndexCache implmentations must implement.
This allows Adapters and the IndexCache Manager to interact with the IndexCache implementation.
author: xenephon (xenephon@jofti.com) |
contains | public boolean contains(Object key) throws JoftiException(Code) | | Returns whether the index contains the key.
Parameters: key - -the key to check throws: JoftiException - - A wrapper for any cache specific exceptions or exceptions generated by the index. |
getAttributesByKey | public Map getAttributesByKey(Object key) throws JoftiException(Code) | | Returns a Map of attribute values that the index has for the key from the index.
Parameters: key - -the key to retrieve the cached object throws: JoftiException - - A wrapper for any cache specific exceptions or exceptions generated by the index. |
getEntries | public Map getEntries(Object key) throws JoftiException(Code) | | Returns the keys that are stored under the entry.
Parameters: key - -the object to check throws: JoftiException - - A wrapper for any cache specific exceptions or exceptions generated by the index. |
getKeyNumber | public long getKeyNumber()(Code) | | |
getParserManager | public ParserManager getParserManager()(Code) | | Returns the parser manager configured in this index.
ParserManager |
insert | public void insert(Object key, Object value) throws IllegalArgumentException, JoftiException(Code) | | Puts an object into the underlying index instance and indexes the object according to
the class definitions in the index config file. Some indexes may only accept certain types of
object.
Parameters: key - value to use as key in the index Parameters: value - value to put into cache and to be indexed throws: JoftiException - thrown as a wrapper exception that contains any index specific exceptions. |
query | public Map query(IndexQuery query) throws JoftiException(Code) | | This queries the index and retrieves a map of matching elements (if any). The map contains
key/value pairs and the result is ordered by the attribute being searched on (if a single attribute is used in the query).
The ordering is preserved in the iteration as it is a @seejava.util.LinkedHashMap.
If you are using a NameSpacedIndex the keys returned
in this map are of type @see NameSpaceKey.
Parameters: query - - the type of query to perform against the index and cache. Map a map of the results
throws: JoftiException - a wrapper exception for errors in the query.
|
remove | public void remove(Object key, Object value) throws IllegalArgumentException, JoftiException(Code) | | Deletes an object from the index. Attempting to remove a non-existent, or expired object will
not generate an exception.
Parameters: key - -the key to retrieve the cached object Parameters: value - - the object to be removed throws: JoftiException - - A wrapper for any cache specific exceptions or exceptions generated by the index. |
removeByKey | public void removeByKey(Object key) throws JoftiException(Code) | | Deletes all entries for the key from the index. Attempting to remove a non-existent, or expired object will
not generate an exception.
Parameters: key - -the key to retrieve the cached object throws: JoftiException - - A wrapper for any cache specific exceptions or exceptions generated by the index. |
|
|