|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.directory.server.core.partition.AbstractPartition
org.apache.directory.server.core.partition.impl.btree.BTreePartition<ID>
public abstract class BTreePartition<ID>
An abstract Partition that uses general BTree operations.
| Field Summary | |
|---|---|
protected int |
cacheSize
|
protected org.apache.directory.shared.ldap.entry.ServerEntry |
contextEntry
The rootDSE context |
protected java.lang.String |
id
|
protected Optimizer |
optimizer
|
protected org.apache.directory.shared.ldap.schema.SchemaManager |
schemaManager
|
protected SearchEngine<org.apache.directory.shared.ldap.entry.ServerEntry,ID> |
searchEngine
the search engine used to search the database |
protected org.apache.directory.shared.ldap.name.DN |
suffix
|
protected static java.util.Set<java.lang.String> |
SYS_INDEX_OIDS
|
| Fields inherited from class org.apache.directory.server.core.partition.AbstractPartition |
|---|
initialized |
| Constructor Summary | |
|---|---|
protected |
BTreePartition()
Creates a B-tree based context partition. |
| Method Summary | |
|---|---|
abstract void |
add(AddOperationContext opContext)
|
void |
addIndexedAttributes(Index<? extends java.lang.Object,org.apache.directory.shared.ldap.entry.ServerEntry,ID>... indexes)
|
abstract void |
addIndexOn(Index<? extends java.lang.Object,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index)
|
abstract int |
count()
Gets the count of the total number of entries in the database. |
void |
delete(DeleteOperationContext opContext)
|
abstract void |
delete(ID id)
|
abstract Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> |
getAliasIndex()
Gets the system index defined on the ALIAS_ATTRIBUTE which for LDAP would be the aliasedObjectName and for X.500 would be aliasedEntryName. |
int |
getCacheSize()
Gets the entry cache size for this BTreePartition. |
abstract int |
getChildCount(ID id)
|
abstract java.lang.String |
getEntryDn(ID id)
|
abstract ID |
getEntryId(java.lang.String dn)
|
abstract java.lang.String |
getEntryUpdn(ID id)
Gets the user provided distinguished name. |
abstract java.lang.String |
getEntryUpdn(java.lang.String dn)
Gets the user provided distinguished name. |
java.lang.String |
getId()
Gets the unique identifier for this partition. |
java.util.Set<Index<? extends java.lang.Object,org.apache.directory.shared.ldap.entry.ServerEntry,ID>> |
getIndexedAttributes()
|
abstract Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> |
getNdnIndex()
Gets the Index mapping the normalized distinguished names of entries as Strings to the BigInteger primary keys of entries. |
abstract Index<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> |
getOneAliasIndex()
Gets the alias index mapping parent entries with scope expanding aliases children one level below them; this system index is used to dereference aliases on one/single level scoped searches. |
abstract Index<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> |
getOneLevelIndex()
Gets the Index mapping the primary keys of parents to the primary keys of their children. |
abstract ID |
getParentId(ID childId)
|
abstract ID |
getParentId(java.lang.String dn)
|
java.io.File |
getPartitionDir()
Gets the directory in which this Partition stores files. |
abstract Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> |
getPresenceIndex()
|
abstract java.lang.String |
getProperty(java.lang.String key)
|
org.apache.directory.shared.ldap.schema.SchemaManager |
getSchemaManager()
|
SearchEngine<org.apache.directory.shared.ldap.entry.ServerEntry,ID> |
getSearchEngine()
Gets the DefaultSearchEngine used by this ContextPartition to search the Database. |
abstract Index<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> |
getSubAliasIndex()
Gets the alias index mapping relative entries with scope expanding alias descendents; this system index is used to dereference aliases on subtree scoped searches. |
abstract Index<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> |
getSubLevelIndex()
Gets the Index mapping the primary keys of ancestors to the primary keys of their descendants. |
java.lang.String |
getSuffix()
|
org.apache.directory.shared.ldap.name.DN |
getSuffixDn()
|
abstract Index<? extends java.lang.Object,org.apache.directory.shared.ldap.entry.ServerEntry,ID> |
getSystemIndex(java.lang.String attribute)
|
abstract java.util.Iterator<java.lang.String> |
getSystemIndices()
|
abstract Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> |
getUpdnIndex()
Gets the Index mapping user provided distinguished names of entries as Strings to the BigInteger primary keys of entries. |
abstract Index<? extends java.lang.Object,org.apache.directory.shared.ldap.entry.ServerEntry,ID> |
getUserIndex(java.lang.String attribute)
|
abstract java.util.Iterator<java.lang.String> |
getUserIndices()
|
boolean |
hasEntry(EntryOperationContext opContext)
|
abstract boolean |
hasSystemIndexOn(java.lang.String attribute)
|
abstract boolean |
hasUserIndexOn(java.lang.String attribute)
|
abstract IndexCursor<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> |
list(ID id)
|
EntryFilteringCursor |
list(ListOperationContext opContext)
|
abstract ClonedServerEntry |
lookup(ID id)
|
ClonedServerEntry |
lookup(LookupOperationContext opContext)
|
abstract void |
modify(ModifyOperationContext opContext)
|
abstract void |
move(MoveOperationContext opContext)
|
abstract void |
moveAndRename(MoveAndRenameOperationContext opContext)
|
abstract void |
rename(RenameOperationContext opContext)
|
EntryFilteringCursor |
search(SearchOperationContext opContext)
|
abstract void |
setAliasIndexOn(Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index)
Sets the system index defined on the ALIAS_ATTRIBUTE which for LDAP would be the aliasedObjectName and for X.500 would be aliasedEntryName. |
void |
setCacheSize(int cacheSize)
Used to specify the entry cache size for a Partition. |
void |
setId(java.lang.String id)
Sets the unique identifier for this partition. |
void |
setIndexedAttributes(java.util.Set<Index<? extends java.lang.Object,org.apache.directory.shared.ldap.entry.ServerEntry,ID>> indexedAttributes)
|
abstract void |
setNdnIndexOn(Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index)
Sets the normalized distinguished name Index. |
abstract void |
setOneAliasIndexOn(Index<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index)
Sets the alias index mapping parent entries with scope expanding aliases children one level below them; this system index is used to dereference aliases on one/single level scoped searches. |
abstract void |
setOneLevelIndexOn(Index<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index)
Sets the one level Index. |
void |
setPartitionDir(java.io.File partitionDir)
Sets the directory in which this Partition stores files. |
abstract void |
setPresenceIndexOn(Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index)
Sets the attribute existence Index. |
abstract void |
setProperty(java.lang.String key,
java.lang.String value)
|
void |
setSchemaManager(org.apache.directory.shared.ldap.schema.SchemaManager schemaManager)
|
abstract void |
setSubAliasIndexOn(Index<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index)
Sets the alias index mapping relative entries with scope expanding alias descendents; this system index is used to dereference aliases on subtree scoped searches. |
void |
setSuffix(java.lang.String suffix)
|
abstract void |
setUpdnIndexOn(Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index)
Sets the user provided distinguished name Index. |
abstract void |
sync()
|
| Methods inherited from class org.apache.directory.server.core.partition.AbstractPartition |
|---|
destroy, doDestroy, doInit, initialize, isInitialized |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.apache.directory.server.core.partition.Partition |
|---|
bind, unbind |
| Field Detail |
|---|
protected static final java.util.Set<java.lang.String> SYS_INDEX_OIDS
protected SearchEngine<org.apache.directory.shared.ldap.entry.ServerEntry,ID> searchEngine
protected Optimizer optimizer
protected org.apache.directory.shared.ldap.schema.SchemaManager schemaManager
protected java.lang.String id
protected int cacheSize
protected org.apache.directory.shared.ldap.name.DN suffix
protected org.apache.directory.shared.ldap.entry.ServerEntry contextEntry
| Constructor Detail |
|---|
protected BTreePartition()
| Method Detail |
|---|
public void setSchemaManager(org.apache.directory.shared.ldap.schema.SchemaManager schemaManager)
public org.apache.directory.shared.ldap.schema.SchemaManager getSchemaManager()
public java.io.File getPartitionDir()
public void setPartitionDir(java.io.File partitionDir)
partitionDir - the directory in which this Partition stores files.public void setIndexedAttributes(java.util.Set<Index<? extends java.lang.Object,org.apache.directory.shared.ldap.entry.ServerEntry,ID>> indexedAttributes)
public void addIndexedAttributes(Index<? extends java.lang.Object,org.apache.directory.shared.ldap.entry.ServerEntry,ID>... indexes)
public java.util.Set<Index<? extends java.lang.Object,org.apache.directory.shared.ldap.entry.ServerEntry,ID>> getIndexedAttributes()
public void setCacheSize(int cacheSize)
cacheSize - the maximum size of the cache in the number of entriespublic int getCacheSize()
public java.lang.String getId()
public void setId(java.lang.String id)
id - the unique identifier for this partitionpublic SearchEngine<org.apache.directory.shared.ldap.entry.ServerEntry,ID> getSearchEngine()
public void delete(DeleteOperationContext opContext)
throws java.lang.Exception
java.lang.Exception
public abstract void add(AddOperationContext opContext)
throws java.lang.Exception
java.lang.Exception
public abstract void modify(ModifyOperationContext opContext)
throws java.lang.Exception
java.lang.Exception
public EntryFilteringCursor list(ListOperationContext opContext)
throws java.lang.Exception
java.lang.Exception
public EntryFilteringCursor search(SearchOperationContext opContext)
throws java.lang.Exception
java.lang.Exception
public ClonedServerEntry lookup(LookupOperationContext opContext)
throws java.lang.Exception
lookup in interface Partitionlookup in class AbstractPartitionjava.lang.Exception
public boolean hasEntry(EntryOperationContext opContext)
throws java.lang.Exception
hasEntry in interface PartitionhasEntry in class AbstractPartitionjava.lang.Exception
public abstract void rename(RenameOperationContext opContext)
throws java.lang.Exception
java.lang.Exception
public abstract void move(MoveOperationContext opContext)
throws java.lang.Exception
java.lang.Exception
public abstract void moveAndRename(MoveAndRenameOperationContext opContext)
throws java.lang.Exception
java.lang.Exception
public abstract void sync()
throws java.lang.Exception
sync in interface Partitionsync in class AbstractPartitionjava.lang.Exception
public abstract void addIndexOn(Index<? extends java.lang.Object,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index)
throws java.lang.Exception
java.lang.Exception
public abstract boolean hasUserIndexOn(java.lang.String attribute)
throws java.lang.Exception
java.lang.Exception
public abstract boolean hasSystemIndexOn(java.lang.String attribute)
throws java.lang.Exception
java.lang.Exceptionpublic abstract Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> getPresenceIndex()
public abstract Index<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> getOneLevelIndex()
public abstract Index<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> getSubLevelIndex()
public abstract Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> getUpdnIndex()
public abstract Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> getNdnIndex()
public abstract Index<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> getOneAliasIndex()
public abstract Index<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> getSubAliasIndex()
public abstract Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> getAliasIndex()
public abstract void setAliasIndexOn(Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index)
throws java.lang.Exception
index - the index on the ALIAS_ATTRIBUTE
java.lang.Exception - if there is a problem setting up the index
public abstract void setPresenceIndexOn(Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index)
throws java.lang.Exception
index - the attribute existence Index
java.lang.Exception - if there is a problem setting up the index
public abstract void setOneLevelIndexOn(Index<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index)
throws java.lang.Exception
index - the one level Index
java.lang.Exception - if there is a problem setting up the index
public abstract void setUpdnIndexOn(Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index)
throws java.lang.Exception
index - the updn Index
java.lang.Exception - if there is a problem setting up the index
public abstract void setNdnIndexOn(Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index)
throws java.lang.Exception
index - the ndn Index
java.lang.Exception - if there is a problem setting up the index
public abstract void setOneAliasIndexOn(Index<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index)
throws java.lang.Exception
index - a one level alias index
java.lang.Exception - if there is a problem setting up the index
public abstract void setSubAliasIndexOn(Index<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index)
throws java.lang.Exception
index - a subtree alias index
java.lang.Exception - if there is a problem setting up the index
public void setSuffix(java.lang.String suffix)
throws org.apache.directory.shared.ldap.exception.LdapInvalidDnException
org.apache.directory.shared.ldap.exception.LdapInvalidDnExceptionpublic java.lang.String getSuffix()
public org.apache.directory.shared.ldap.name.DN getSuffixDn()
public abstract Index<? extends java.lang.Object,org.apache.directory.shared.ldap.entry.ServerEntry,ID> getUserIndex(java.lang.String attribute)
throws java.lang.Exception
java.lang.Exception
public abstract Index<? extends java.lang.Object,org.apache.directory.shared.ldap.entry.ServerEntry,ID> getSystemIndex(java.lang.String attribute)
throws java.lang.Exception
java.lang.Exception
public abstract ID getEntryId(java.lang.String dn)
throws java.lang.Exception
java.lang.Exception
public abstract java.lang.String getEntryDn(ID id)
throws java.lang.Exception
java.lang.Exception
public abstract ID getParentId(java.lang.String dn)
throws java.lang.Exception
java.lang.Exception
public abstract ID getParentId(ID childId)
throws java.lang.Exception
java.lang.Exception
public abstract java.lang.String getEntryUpdn(ID id)
throws java.lang.Exception
id - the entry id
java.lang.Exception - if the updn index cannot be accessed
public abstract java.lang.String getEntryUpdn(java.lang.String dn)
throws java.lang.Exception
dn - the normalized distinguished name
java.lang.Exception - if the updn and ndn indices cannot be accessed
public abstract ClonedServerEntry lookup(ID id)
throws java.lang.Exception
java.lang.Exception
public abstract void delete(ID id)
throws java.lang.Exception
java.lang.Exception
public abstract IndexCursor<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> list(ID id)
throws java.lang.Exception
java.lang.Exception
public abstract int getChildCount(ID id)
throws java.lang.Exception
java.lang.Exception
public abstract void setProperty(java.lang.String key,
java.lang.String value)
throws java.lang.Exception
java.lang.Exception
public abstract java.lang.String getProperty(java.lang.String key)
throws java.lang.Exception
java.lang.Exceptionpublic abstract java.util.Iterator<java.lang.String> getUserIndices()
public abstract java.util.Iterator<java.lang.String> getSystemIndices()
public abstract int count()
throws java.lang.Exception
java.lang.Exception - if there is a failure to read the count
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||