|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.directory.server.core.partition.impl.btree.BTreePartition
org.apache.directory.server.core.partition.impl.btree.jdbm.JdbmPartition
public class JdbmPartition
A Partition
that stores entries in
JDBM database.
Field Summary |
---|
Fields inherited from interface org.apache.directory.server.core.partition.Partition |
---|
ALIAS_ATTRIBUTE, ALIAS_OBJECT |
Constructor Summary | |
---|---|
JdbmPartition()
Creates a store based on JDBM B+Trees. |
Method Summary | |
---|---|
void |
add(org.apache.directory.shared.ldap.name.LdapDN normName,
javax.naming.directory.Attributes entry)
Adds an entry to this ContextPartition. |
void |
addIndexOn(org.apache.directory.shared.ldap.schema.AttributeType spec,
int cacheSize,
int numDupLimit)
|
void |
bind(org.apache.directory.shared.ldap.name.LdapDN bindDn,
byte[] credentials,
java.util.List mechanisms,
java.lang.String saslAuthId)
Represents a bind operation issued to authenticate a client. |
int |
count()
Gets the count of the total number of entries in the database. |
void |
delete(java.math.BigInteger id)
|
void |
destroy()
Deinitialized this partition. |
Index |
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(java.math.BigInteger id)
|
java.lang.String |
getEntryDn(java.math.BigInteger id)
|
java.math.BigInteger |
getEntryId(java.lang.String dn)
|
java.lang.String |
getEntryUpdn(java.math.BigInteger id)
Gets the user provided distinguished name. |
java.lang.String |
getEntryUpdn(java.lang.String dn)
Gets the user provided distinguished name. |
Index |
getExistanceIndex()
|
Index |
getHierarchyIndex()
Gets the Index mapping the BigInteger primary keys of parents to the BigInteger primary keys of their children. |
javax.naming.directory.Attributes |
getIndices(java.math.BigInteger id)
|
Index |
getNdnIndex()
Gets the Index mapping the normalized distinguished names of entries as Strings to the BigInteger primary keys of entries. |
Index |
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. |
java.math.BigInteger |
getParentId(java.math.BigInteger childId)
|
java.math.BigInteger |
getParentId(java.lang.String dn)
|
java.lang.String |
getProperty(java.lang.String propertyName)
|
Index |
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. |
org.apache.directory.shared.ldap.name.LdapDN |
getSuffix()
Gets the distinguished/absolute name of the suffix for all entries stored within this ContextPartition. |
javax.naming.directory.Attributes |
getSuffixEntry()
|
Index |
getSystemIndex(java.lang.String id)
|
java.util.Iterator |
getSystemIndices()
|
Index |
getUpdnIndex()
Gets the Index mapping user provided distinguished names of entries as Strings to the BigInteger primary keys of entries. |
org.apache.directory.shared.ldap.name.LdapDN |
getUpSuffix()
Gets the distinguished/absolute name of the suffix for all entries stored within this ContextPartition. |
Index |
getUserIndex(java.lang.String id)
|
java.util.Iterator |
getUserIndices()
|
boolean |
hasSystemIndexOn(java.lang.String id)
|
boolean |
hasUserIndexOn(java.lang.String id)
|
void |
init(DirectoryServiceConfiguration factoryCfg,
PartitionConfiguration cfg)
Initializes this partition. |
boolean |
isInitialized()
Checks to see if this partition is initialized or not. |
javax.naming.NamingEnumeration |
list(java.math.BigInteger id)
|
javax.naming.directory.Attributes |
lookup(java.math.BigInteger id)
|
void |
modify(org.apache.directory.shared.ldap.name.LdapDN dn,
int modOp,
javax.naming.directory.Attributes mods)
Modifies an entry by adding, removing or replacing a set of attributes. |
void |
modify(org.apache.directory.shared.ldap.name.LdapDN dn,
org.apache.directory.shared.ldap.message.ModificationItemImpl[] mods)
Modifies an entry by using a combination of adds, removes or replace operations using a set of ModificationItems. |
void |
modifyRn(org.apache.directory.shared.ldap.name.LdapDN dn,
java.lang.String newRdn,
boolean deleteOldRdn)
Changes the relative distinuished name of an entry specified by a distinguished name with the optional removal of the old Rdn attribute value from the entry. |
void |
move(org.apache.directory.shared.ldap.name.LdapDN oldChildDn,
org.apache.directory.shared.ldap.name.LdapDN newParentDn)
Transplants a child entry, to a position in the namespace under a new parent entry. |
void |
move(org.apache.directory.shared.ldap.name.LdapDN oldChildDn,
org.apache.directory.shared.ldap.name.LdapDN newParentDn,
java.lang.String newRdn,
boolean deleteOldRdn)
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 |
setAliasIndexOn(org.apache.directory.shared.ldap.schema.AttributeType attrType,
int cacheSize,
int numDupLimit)
Sets the system index defined on the ALIAS_ATTRIBUTE which for LDAP would be the aliasedObjectName and for X.500 would be aliasedEntryName. |
void |
setExistanceIndexOn(org.apache.directory.shared.ldap.schema.AttributeType attrType,
int cacheSize,
int numDupLimit)
Sets the attribute existance Index. |
void |
setHierarchyIndexOn(org.apache.directory.shared.ldap.schema.AttributeType attrType,
int cacheSize,
int numDupLimit)
Sets the hierarchy Index. |
void |
setNdnIndexOn(org.apache.directory.shared.ldap.schema.AttributeType attrType,
int cacheSize,
int numDupLimit)
Sets the normalized distinguished name Index. |
void |
setOneAliasIndexOn(org.apache.directory.shared.ldap.schema.AttributeType attrType,
int cacheSize,
int numDupLimit)
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 |
setProperty(java.lang.String propertyName,
java.lang.String propertyValue)
|
void |
setSubAliasIndexOn(org.apache.directory.shared.ldap.schema.AttributeType attrType,
int cacheSize,
int numDupLimit)
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 |
setUpdnIndexOn(org.apache.directory.shared.ldap.schema.AttributeType attrType,
int cacheSize,
int numDupLimit)
Sets the user provided distinguished name Index. |
void |
sync()
Flushes any changes made to this partition now. |
void |
unbind(org.apache.directory.shared.ldap.name.LdapDN bindDn)
Represents an unbind operation issued by an authenticated client. |
Methods inherited from class org.apache.directory.server.core.partition.impl.btree.BTreePartition |
---|
delete, getSearchEngine, hasEntry, inspect, isSuffix, list, lookup, lookup, search |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public JdbmPartition()
Method Detail |
---|
public void init(DirectoryServiceConfiguration factoryCfg, PartitionConfiguration cfg) throws javax.naming.NamingException
Partition
init
in interface Partition
init
in class BTreePartition
javax.naming.NamingException
public void destroy()
Partition
destroy
in interface Partition
destroy
in class BTreePartition
public boolean isInitialized()
Partition
isInitialized
in interface Partition
isInitialized
in class BTreePartition
public void sync() throws javax.naming.NamingException
Partition
sync
in interface Partition
sync
in class BTreePartition
javax.naming.NamingException
public void addIndexOn(org.apache.directory.shared.ldap.schema.AttributeType spec, int cacheSize, int numDupLimit) throws javax.naming.NamingException
addIndexOn
in class BTreePartition
javax.naming.NamingException
public Index getExistanceIndex()
getExistanceIndex
in class BTreePartition
public void setExistanceIndexOn(org.apache.directory.shared.ldap.schema.AttributeType attrType, int cacheSize, int numDupLimit) throws javax.naming.NamingException
BTreePartition
setExistanceIndexOn
in class BTreePartition
attrType
- the attribute existance Index
javax.naming.NamingException
public Index getHierarchyIndex()
BTreePartition
getHierarchyIndex
in class BTreePartition
public void setHierarchyIndexOn(org.apache.directory.shared.ldap.schema.AttributeType attrType, int cacheSize, int numDupLimit) throws javax.naming.NamingException
BTreePartition
setHierarchyIndexOn
in class BTreePartition
attrType
- the hierarchy Index
javax.naming.NamingException
public Index getAliasIndex()
BTreePartition
getAliasIndex
in class BTreePartition
public void setAliasIndexOn(org.apache.directory.shared.ldap.schema.AttributeType attrType, int cacheSize, int numDupLimit) throws javax.naming.NamingException
BTreePartition
setAliasIndexOn
in class BTreePartition
attrType
- the index on the ALIAS_ATTRIBUTE
javax.naming.NamingException
public Index getOneAliasIndex()
BTreePartition
getOneAliasIndex
in class BTreePartition
public void setOneAliasIndexOn(org.apache.directory.shared.ldap.schema.AttributeType attrType, int cacheSize, int numDupLimit) throws javax.naming.NamingException
BTreePartition
setOneAliasIndexOn
in class BTreePartition
attrType
- a one level alias index
javax.naming.NamingException
public Index getSubAliasIndex()
BTreePartition
getSubAliasIndex
in class BTreePartition
public void setSubAliasIndexOn(org.apache.directory.shared.ldap.schema.AttributeType attrType, int cacheSize, int numDupLimit) throws javax.naming.NamingException
BTreePartition
setSubAliasIndexOn
in class BTreePartition
attrType
- a subtree alias index
javax.naming.NamingException
public Index getUpdnIndex()
BTreePartition
getUpdnIndex
in class BTreePartition
public void setUpdnIndexOn(org.apache.directory.shared.ldap.schema.AttributeType attrType, int cacheSize, int numDupLimit) throws javax.naming.NamingException
BTreePartition
setUpdnIndexOn
in class BTreePartition
attrType
- the updn Index
javax.naming.NamingException
public Index getNdnIndex()
BTreePartition
getNdnIndex
in class BTreePartition
public void setNdnIndexOn(org.apache.directory.shared.ldap.schema.AttributeType attrType, int cacheSize, int numDupLimit) throws javax.naming.NamingException
BTreePartition
setNdnIndexOn
in class BTreePartition
attrType
- the ndn Index
javax.naming.NamingException
public java.util.Iterator getUserIndices()
getUserIndices
in class BTreePartition
public java.util.Iterator getSystemIndices()
getSystemIndices
in class BTreePartition
public boolean hasUserIndexOn(java.lang.String id) throws javax.naming.NamingException
hasUserIndexOn
in class BTreePartition
javax.naming.NamingException
public boolean hasSystemIndexOn(java.lang.String id) throws javax.naming.NamingException
hasSystemIndexOn
in class BTreePartition
javax.naming.NamingException
public Index getUserIndex(java.lang.String id) throws IndexNotFoundException
getUserIndex
in class BTreePartition
IndexNotFoundException
BTreePartition.getUserIndex(String)
public Index getSystemIndex(java.lang.String id) throws IndexNotFoundException
getSystemIndex
in class BTreePartition
IndexNotFoundException
BTreePartition.getEntryId(String)
public java.math.BigInteger getEntryId(java.lang.String dn) throws javax.naming.NamingException
getEntryId
in class BTreePartition
javax.naming.NamingException
public java.lang.String getEntryDn(java.math.BigInteger id) throws javax.naming.NamingException
getEntryDn
in class BTreePartition
javax.naming.NamingException
public java.math.BigInteger getParentId(java.lang.String dn) throws javax.naming.NamingException
getParentId
in class BTreePartition
javax.naming.NamingException
public java.math.BigInteger getParentId(java.math.BigInteger childId) throws javax.naming.NamingException
getParentId
in class BTreePartition
javax.naming.NamingException
public java.lang.String getEntryUpdn(java.math.BigInteger id) throws javax.naming.NamingException
BTreePartition
getEntryUpdn
in class BTreePartition
id
- the entry id
javax.naming.NamingException
- if the updn index cannot be accessedpublic java.lang.String getEntryUpdn(java.lang.String dn) throws javax.naming.NamingException
BTreePartition
getEntryUpdn
in class BTreePartition
dn
- the normalized distinguished name
javax.naming.NamingException
- if the updn and ndn indices cannot be accessedpublic int count() throws javax.naming.NamingException
BTreePartition
count
in class BTreePartition
javax.naming.NamingException
- if there is a failure to read the countpublic void add(org.apache.directory.shared.ldap.name.LdapDN normName, javax.naming.directory.Attributes entry) throws javax.naming.NamingException
Partition
add
in interface Partition
add
in class BTreePartition
entry
- the entry to add to this ContextPartition
javax.naming.NamingException
- if there are any problemspublic javax.naming.directory.Attributes lookup(java.math.BigInteger id) throws javax.naming.NamingException
lookup
in class BTreePartition
javax.naming.NamingException
public void delete(java.math.BigInteger id) throws javax.naming.NamingException
delete
in class BTreePartition
javax.naming.NamingException
public javax.naming.NamingEnumeration list(java.math.BigInteger id) throws javax.naming.NamingException
list
in class BTreePartition
javax.naming.NamingException
public int getChildCount(java.math.BigInteger id) throws javax.naming.NamingException
getChildCount
in class BTreePartition
javax.naming.NamingException
public org.apache.directory.shared.ldap.name.LdapDN getSuffix()
Partition
public org.apache.directory.shared.ldap.name.LdapDN getUpSuffix()
Partition
public javax.naming.directory.Attributes getSuffixEntry() throws javax.naming.NamingException
getSuffixEntry
in class BTreePartition
javax.naming.NamingException
public void setProperty(java.lang.String propertyName, java.lang.String propertyValue) throws javax.naming.NamingException
setProperty
in class BTreePartition
javax.naming.NamingException
public java.lang.String getProperty(java.lang.String propertyName) throws javax.naming.NamingException
getProperty
in class BTreePartition
javax.naming.NamingException
public javax.naming.directory.Attributes getIndices(java.math.BigInteger id) throws javax.naming.NamingException
getIndices
in class BTreePartition
javax.naming.NamingException
public void modify(org.apache.directory.shared.ldap.name.LdapDN dn, int modOp, javax.naming.directory.Attributes mods) throws javax.naming.NamingException
Partition
modify
in interface Partition
modify
in class BTreePartition
dn
- the normalized distinguished/absolute name of the entry to
modifymodOp
- the modification operation to perform on the entry which
is one of constants specified by the DirContext interface:
ADD_ATTRIBUTE, REMOVE_ATTRIBUTE, REPLACE_ATTRIBUTE
.mods
- the attributes and their values used to affect the
modification with.
javax.naming.NamingException
- if there are any problemsDirContext
,
DirContext.ADD_ATTRIBUTE
,
DirContext.REMOVE_ATTRIBUTE
,
DirContext.REPLACE_ATTRIBUTE
public void modify(org.apache.directory.shared.ldap.name.LdapDN dn, org.apache.directory.shared.ldap.message.ModificationItemImpl[] mods) throws javax.naming.NamingException
Partition
modify
in interface Partition
modify
in class BTreePartition
dn
- the normalized distinguished/absolute name of the entry to modifymods
- the ModificationItems used to affect the modification with
javax.naming.NamingException
- if there are any problemsModificationItem
public void modifyRn(org.apache.directory.shared.ldap.name.LdapDN dn, java.lang.String newRdn, boolean deleteOldRdn) throws javax.naming.NamingException
modifyRn
in interface Partition
modifyRn
in class BTreePartition
dn
- the normalized distinguished name of the entry to alternewRdn
- the new Rdn to setdeleteOldRdn
- whether or not to remove the old Rdn attr/val
javax.naming.NamingException
- if there are any errors propagating the name
changes.public void move(org.apache.directory.shared.ldap.name.LdapDN oldChildDn, org.apache.directory.shared.ldap.name.LdapDN newParentDn, java.lang.String newRdn, boolean deleteOldRdn) throws javax.naming.NamingException
Partition
move
in interface Partition
move
in class BTreePartition
oldChildDn
- the normalized distinguished/absolute name of the
original child name representing the child entry to movenewParentDn
- the normalized distinguished/absolute name of the
new parent to move the targeted entry tonewRdn
- the new RN of the entrydeleteOldRdn
- boolean flag which removes the old RN attribute
from the entry if set to true, and has no affect if set to false
javax.naming.NamingException
- if there are any problemspublic void move(org.apache.directory.shared.ldap.name.LdapDN oldChildDn, org.apache.directory.shared.ldap.name.LdapDN newParentDn) throws javax.naming.NamingException
Partition
move
in interface Partition
move
in class BTreePartition
oldChildDn
- the normalized distinguished/absolute name of the
original child name representing the child entry to movenewParentDn
- the normalized distinguished/absolute name of the
new parent to move the target entry to
javax.naming.NamingException
- if there are any problemspublic void bind(org.apache.directory.shared.ldap.name.LdapDN bindDn, byte[] credentials, java.util.List mechanisms, java.lang.String saslAuthId) throws javax.naming.NamingException
Partition
bindDn
- the normalized dn of the principalcredentials
- the credentials of the principalmechanisms
- the mechanisms requested by the JNDI caller or a single
mechanism representing the SASL bind mechanism used by a networked client (Strings)saslAuthId
- the SASL authentication (may be null)
javax.naming.NamingException
- if something goes wrongpublic void unbind(org.apache.directory.shared.ldap.name.LdapDN bindDn) throws javax.naming.NamingException
Partition
bindDn
- the normalized dn of the principal attempting to unbind
javax.naming.NamingException
- if something goes wrong
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |