|
||||||||||
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>
org.apache.directory.server.xdbm.AbstractXdbmPartition<ID>
public abstract class AbstractXdbmPartition<ID>
Base class for XDBM partitions that use an Store
.
Field Summary | |
---|---|
protected boolean |
optimizerEnabled
|
protected Store<org.apache.directory.shared.ldap.entry.ServerEntry,ID> |
store
The store. |
Fields inherited from class org.apache.directory.server.core.partition.impl.btree.BTreePartition |
---|
cacheSize, contextEntry, id, optimizer, schemaManager, searchEngine, suffix, SYS_INDEX_OIDS |
Fields inherited from class org.apache.directory.server.core.partition.AbstractPartition |
---|
initialized |
Constructor Summary | |
---|---|
protected |
AbstractXdbmPartition(Store<org.apache.directory.shared.ldap.entry.ServerEntry,ID> store)
|
Method Summary | |
---|---|
void |
add(AddOperationContext addContext)
Adds an entry to this ContextPartition. |
void |
addIndexOn(Index<? extends java.lang.Object,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index)
|
void |
bind(BindOperationContext bindContext)
Represents a bind operation issued to authenticate a client. |
void |
bind(org.apache.directory.shared.ldap.name.DN bindDn,
byte[] credentials,
java.util.List<java.lang.String> mechanisms,
java.lang.String saslAuthId)
|
int |
count()
Gets the count of the total number of entries in the database. |
void |
delete(ID id)
|
protected void |
doDestroy()
Override this method to put your initialization code. |
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 |
getChildCount(ID id)
|
java.lang.String |
getEntryDn(ID id)
|
ID |
getEntryId(java.lang.String dn)
|
java.lang.String |
getEntryUpdn(ID id)
Gets the user provided distinguished name. |
java.lang.String |
getEntryUpdn(java.lang.String dn)
Gets the user provided distinguished name. |
Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> |
getExistenceIndex()
|
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. |
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. |
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. |
ID |
getParentId(ID childId)
|
ID |
getParentId(java.lang.String dn)
|
Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> |
getPresenceIndex()
|
java.lang.String |
getProperty(java.lang.String propertyName)
|
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. |
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. |
Index<? extends java.lang.Object,org.apache.directory.shared.ldap.entry.ServerEntry,ID> |
getSystemIndex(java.lang.String id)
|
java.util.Iterator<java.lang.String> |
getSystemIndices()
|
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. |
Index<? extends java.lang.Object,org.apache.directory.shared.ldap.entry.ServerEntry,ID> |
getUserIndex(java.lang.String id)
|
java.util.Iterator<java.lang.String> |
getUserIndices()
|
boolean |
hasSystemIndexOn(java.lang.String id)
|
boolean |
hasUserIndexOn(java.lang.String id)
|
boolean |
isInitialized()
Returns true if this context partition is initialized successfully. |
boolean |
isOptimizerEnabled()
|
boolean |
isSyncOnWrite()
|
IndexCursor<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> |
list(ID id)
|
ClonedServerEntry |
lookup(ID id)
|
void |
modify(ModifyOperationContext modifyContext)
Modifies an entry by adding, removing or replacing a set of attributes. |
void |
move(MoveOperationContext moveContext)
Transplants a child entry, to a position in the namespace under a new parent entry. |
void |
moveAndRename(MoveAndRenameOperationContext moveAndRenameContext)
Transplants a child entry, to a position in the namespace under a new parent entry and changes the RN of the child entry which can optionally have its old RN attributes removed. |
void |
rename(RenameOperationContext renameContext)
Modifies an entry by changing its relative name. |
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 |
setNdnIndexOn(Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index)
Sets the normalized distinguished name Index. |
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. |
void |
setOneLevelIndexOn(Index<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index)
Sets the one level Index. |
void |
setOptimizerEnabled(boolean optimizerEnabled)
|
void |
setPresenceIndexOn(Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index)
Sets the attribute existence Index. |
void |
setProperty(java.lang.String propertyName,
java.lang.String propertyValue)
|
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 |
setSyncOnWrite(boolean syncOnWrite)
|
void |
setUpdnIndexOn(Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index)
Sets the user provided distinguished name Index. |
void |
sync()
This method does nothing by default. |
java.lang.String |
toString()
|
void |
unbind(UnbindOperationContext unbindContext)
Represents an unbind operation issued by an authenticated client. |
Methods inherited from class org.apache.directory.server.core.partition.impl.btree.BTreePartition |
---|
addIndexedAttributes, delete, getCacheSize, getId, getIndexedAttributes, getPartitionDir, getSchemaManager, getSearchEngine, getSuffix, getSuffixDn, hasEntry, list, lookup, search, setCacheSize, setId, setIndexedAttributes, setPartitionDir, setSchemaManager, setSuffix |
Methods inherited from class org.apache.directory.server.core.partition.AbstractPartition |
---|
destroy, doInit, initialize |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected boolean optimizerEnabled
protected Store<org.apache.directory.shared.ldap.entry.ServerEntry,ID> store
Constructor Detail |
---|
protected AbstractXdbmPartition(Store<org.apache.directory.shared.ldap.entry.ServerEntry,ID> store)
Method Detail |
---|
protected void doDestroy() throws java.lang.Exception
doDestroy
in class AbstractPartition
java.lang.Exception
public final boolean isInitialized()
isInitialized
in interface Partition
isInitialized
in class AbstractPartition
public final void sync() throws java.lang.Exception
sync
in interface Partition
sync
in class BTreePartition<ID>
java.lang.Exception
- if buffers cannot be flushed to diskpublic boolean isOptimizerEnabled()
public void setOptimizerEnabled(boolean optimizerEnabled)
public void setSyncOnWrite(boolean syncOnWrite)
public boolean isSyncOnWrite()
public final void addIndexOn(Index<? extends java.lang.Object,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index) throws java.lang.Exception
addIndexOn
in class BTreePartition<ID>
java.lang.Exception
public final Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> getExistenceIndex()
public final void setPresenceIndexOn(Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index) throws java.lang.Exception
BTreePartition
setPresenceIndexOn
in class BTreePartition<ID>
index
- the attribute existence Index
java.lang.Exception
- if there is a problem setting up the indexpublic final Index<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> getOneLevelIndex()
BTreePartition
getOneLevelIndex
in class BTreePartition<ID>
public final void setOneLevelIndexOn(Index<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index) throws java.lang.Exception
BTreePartition
setOneLevelIndexOn
in class BTreePartition<ID>
index
- the one level Index
java.lang.Exception
- if there is a problem setting up the indexpublic final Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> getAliasIndex()
BTreePartition
getAliasIndex
in class BTreePartition<ID>
public final void setAliasIndexOn(Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index) throws java.lang.Exception
BTreePartition
setAliasIndexOn
in class BTreePartition<ID>
index
- the index on the ALIAS_ATTRIBUTE
java.lang.Exception
- if there is a problem setting up the indexpublic final Index<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> getOneAliasIndex()
BTreePartition
getOneAliasIndex
in class BTreePartition<ID>
public final void setOneAliasIndexOn(Index<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index) throws java.lang.Exception
BTreePartition
setOneAliasIndexOn
in class BTreePartition<ID>
index
- a one level alias index
java.lang.Exception
- if there is a problem setting up the indexpublic final Index<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> getSubAliasIndex()
BTreePartition
getSubAliasIndex
in class BTreePartition<ID>
public final void setSubAliasIndexOn(Index<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index) throws java.lang.Exception
BTreePartition
setSubAliasIndexOn
in class BTreePartition<ID>
index
- a subtree alias index
java.lang.Exception
- if there is a problem setting up the indexpublic final Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> getUpdnIndex()
BTreePartition
getUpdnIndex
in class BTreePartition<ID>
public final void setUpdnIndexOn(Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index) throws java.lang.Exception
BTreePartition
setUpdnIndexOn
in class BTreePartition<ID>
index
- the updn Index
java.lang.Exception
- if there is a problem setting up the indexpublic final Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> getNdnIndex()
BTreePartition
getNdnIndex
in class BTreePartition<ID>
public final void setNdnIndexOn(Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> index) throws java.lang.Exception
BTreePartition
setNdnIndexOn
in class BTreePartition<ID>
index
- the ndn Index
java.lang.Exception
- if there is a problem setting up the indexpublic final java.util.Iterator<java.lang.String> getUserIndices()
getUserIndices
in class BTreePartition<ID>
public final java.util.Iterator<java.lang.String> getSystemIndices()
getSystemIndices
in class BTreePartition<ID>
public final boolean hasUserIndexOn(java.lang.String id) throws java.lang.Exception
hasUserIndexOn
in class BTreePartition<ID>
java.lang.Exception
public final boolean hasSystemIndexOn(java.lang.String id) throws java.lang.Exception
hasSystemIndexOn
in class BTreePartition<ID>
java.lang.Exception
public final Index<? extends java.lang.Object,org.apache.directory.shared.ldap.entry.ServerEntry,ID> getUserIndex(java.lang.String id) throws IndexNotFoundException
getUserIndex
in class BTreePartition<ID>
IndexNotFoundException
BTreePartition.getUserIndex(String)
public final Index<? extends java.lang.Object,org.apache.directory.shared.ldap.entry.ServerEntry,ID> getSystemIndex(java.lang.String id) throws IndexNotFoundException
getSystemIndex
in class BTreePartition<ID>
IndexNotFoundException
BTreePartition.getEntryId(String)
public final ID getEntryId(java.lang.String dn) throws java.lang.Exception
getEntryId
in class BTreePartition<ID>
java.lang.Exception
public final java.lang.String getEntryDn(ID id) throws java.lang.Exception
getEntryDn
in class BTreePartition<ID>
java.lang.Exception
public final ID getParentId(java.lang.String dn) throws java.lang.Exception
getParentId
in class BTreePartition<ID>
java.lang.Exception
public final ID getParentId(ID childId) throws java.lang.Exception
getParentId
in class BTreePartition<ID>
java.lang.Exception
public final java.lang.String getEntryUpdn(ID id) throws java.lang.Exception
BTreePartition
getEntryUpdn
in class BTreePartition<ID>
id
- the entry id
java.lang.Exception
- if the updn index cannot be accessedpublic final java.lang.String getEntryUpdn(java.lang.String dn) throws java.lang.Exception
BTreePartition
getEntryUpdn
in class BTreePartition<ID>
dn
- the normalized distinguished name
java.lang.Exception
- if the updn and ndn indices cannot be accessedpublic final int count() throws java.lang.Exception
BTreePartition
count
in class BTreePartition<ID>
java.lang.Exception
- if there is a failure to read the countpublic final void add(AddOperationContext addContext) throws java.lang.Exception
Partition
add
in interface Partition
add
in class BTreePartition<ID>
addContext
- the context used to add and entry to this ContextPartition
java.lang.Exception
- if there are any problemspublic final ClonedServerEntry lookup(ID id) throws java.lang.Exception
lookup
in class BTreePartition<ID>
java.lang.Exception
public final void delete(ID id) throws java.lang.Exception
delete
in class BTreePartition<ID>
java.lang.Exception
public final IndexCursor<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> list(ID id) throws java.lang.Exception
list
in class BTreePartition<ID>
java.lang.Exception
public final int getChildCount(ID id) throws java.lang.Exception
getChildCount
in class BTreePartition<ID>
java.lang.Exception
public final void setProperty(java.lang.String propertyName, java.lang.String propertyValue) throws java.lang.Exception
setProperty
in class BTreePartition<ID>
java.lang.Exception
public final java.lang.String getProperty(java.lang.String propertyName) throws java.lang.Exception
getProperty
in class BTreePartition<ID>
java.lang.Exception
public final void modify(ModifyOperationContext modifyContext) throws java.lang.Exception
Partition
modify
in interface Partition
modify
in class BTreePartition<ID>
modifyContext
- The context containing the modification operation
to perform on the entry which is one of constants specified by the
DirContext interface:
ADD_ATTRIBUTE, REMOVE_ATTRIBUTE, REPLACE_ATTRIBUTE
.
java.lang.Exception
- if there are any problemsDirContext
,
DirContext.ADD_ATTRIBUTE
,
DirContext.REMOVE_ATTRIBUTE
,
DirContext.REPLACE_ATTRIBUTE
public final void rename(RenameOperationContext renameContext) throws java.lang.Exception
Partition
rename
in interface Partition
rename
in class BTreePartition<ID>
renameContext
- the modify DN context
java.lang.Exception
- if there are any problemspublic final void moveAndRename(MoveAndRenameOperationContext moveAndRenameContext) throws java.lang.Exception
Partition
moveAndRename
in interface Partition
moveAndRename
in class BTreePartition<ID>
moveAndRenameContext
- The context contain all the information about
the modifyDN operation
java.lang.Exception
- if there are any problemspublic final void move(MoveOperationContext moveContext) throws java.lang.Exception
Partition
move
in interface Partition
move
in class BTreePartition<ID>
moveContext
- The context containing the DNs to move
java.lang.Exception
- if there are any problemspublic final void bind(org.apache.directory.shared.ldap.name.DN bindDn, byte[] credentials, java.util.List<java.lang.String> mechanisms, java.lang.String saslAuthId) throws java.lang.Exception
java.lang.Exception
public final void bind(BindOperationContext bindContext) throws java.lang.Exception
Partition
bindContext
- the bind context, containing all the needed informations to bind
java.lang.Exception
- if something goes wrongpublic final void unbind(UnbindOperationContext unbindContext) throws java.lang.Exception
Partition
unbindContext
- the context used to unbind
java.lang.Exception
- if something goes wrongpublic final Index<java.lang.String,org.apache.directory.shared.ldap.entry.ServerEntry,ID> getPresenceIndex()
getPresenceIndex
in class BTreePartition<ID>
public final Index<ID,org.apache.directory.shared.ldap.entry.ServerEntry,ID> getSubLevelIndex()
BTreePartition
getSubLevelIndex
in class BTreePartition<ID>
public java.lang.String toString()
toString
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |