| Constructor and Description |
|---|
JdbmStore()
Creates a store based on JDBM B+Trees.
|
| Modifier and Type | Method and Description |
|---|---|
void |
add(org.apache.directory.shared.ldap.entry.ServerEntry entry)
Add an entry into the store.
|
void |
addIndex(Index<?,E,Long> index)
Adds a user index to the list of index for this store
|
int |
count() |
void |
delete(Long id)
Delete the entry associated with a given Id
|
void |
destroy()
Close the partition : we have to close all the userIndices and the master table.
|
Index<String,E,Long> |
getAliasIndex() |
int |
getCacheSize() |
int |
getChildCount(Long id) |
Long |
getDefaultId()
Gets the default ID.
|
Index<String,E,Long> |
getEntryCsnIndex() |
String |
getEntryDn(Long id) |
Long |
getEntryId(String dn) |
String |
getEntryUpdn(Long id) |
String |
getEntryUpdn(String dn) |
Index<String,E,Long> |
getEntryUuidIndex() |
Index<?,E,Long> |
getIndex(String id)
Get the user or system index associated with the given name
|
String |
getName() |
Index<String,E,Long> |
getNdnIndex() |
Index<String,E,Long> |
getObjectClassIndex() |
Index<Long,E,Long> |
getOneAliasIndex() |
Index<Long,E,Long> |
getOneLevelIndex() |
Long |
getParentId(Long childId) |
Long |
getParentId(String dn)
Gets the Long id of an entry's parent using the child entry's
normalized DN.
|
Index<String,E,Long> |
getPresenceIndex() |
String |
getProperty(String propertyName) |
Index<Long,E,Long> |
getSubAliasIndex() |
Index<Long,E,Long> |
getSubLevelIndex() |
org.apache.directory.shared.ldap.name.DN |
getSuffix() |
String |
getSuffixDn() |
Index<?,E,Long> |
getSystemIndex(String id)
Get the system index associated with the given name
|
Index<String,E,Long> |
getUpdnIndex() |
org.apache.directory.shared.ldap.name.DN |
getUpSuffix() |
Index<?,E,Long> |
getUserIndex(String id)
Get the user index associated with the given name
|
Set<Index<?,E,Long>> |
getUserIndices() |
File |
getWorkingDirectory() |
boolean |
hasIndexOn(String id)
Tells if an index is already present in the User's or System's index list
|
boolean |
hasSystemIndexOn(String id)
Tells if an index is already present in the System's index list
|
boolean |
hasUserIndexOn(String id)
Tells if an index is already present in the User's index list
|
void |
init(org.apache.directory.shared.ldap.schema.SchemaManager schemaManager)
Initialize the JDBM storage system.
|
boolean |
isInitialized()
Gets whether the store is initialized.
|
boolean |
isSyncOnWrite() |
IndexCursor<Long,E,Long> |
list(Long id)
Gets an IndexEntry Cursor over the child nodes of an entry.
|
org.apache.directory.shared.ldap.entry.ServerEntry |
lookup(Long id) |
void |
modify(org.apache.directory.shared.ldap.name.DN dn,
List<org.apache.directory.shared.ldap.entry.Modification> mods) |
void |
modify(org.apache.directory.shared.ldap.name.DN dn,
org.apache.directory.shared.ldap.entry.ModificationOperation modOp,
org.apache.directory.shared.ldap.entry.ServerEntry mods) |
void |
move(org.apache.directory.shared.ldap.name.DN oldChildDn,
org.apache.directory.shared.ldap.name.DN newParentDn) |
void |
move(org.apache.directory.shared.ldap.name.DN oldChildDn,
org.apache.directory.shared.ldap.name.DN newParentDn,
org.apache.directory.shared.ldap.name.RDN newRdn,
boolean deleteOldRdn) |
void |
rename(org.apache.directory.shared.ldap.name.DN dn,
org.apache.directory.shared.ldap.name.RDN newRdn,
boolean deleteOldRdn)
Changes the relative distinguished name of an entry specified by a
distinguished name with the optional removal of the old RDN attribute
value from the entry.
|
void |
setAliasIndex(Index<String,E,Long> index)
Set the Alias index
|
void |
setCacheSize(int cacheSize)
Sets the cache size for this store
|
void |
setEntryCsnIndex(Index<String,E,Long> index)
Set the EntryCSN index
|
void |
setEntryUuidIndex(Index<String,E,Long> index)
Set the EntryUUID index
|
void |
setName(String name)
Sets the store's name
|
void |
setNdnIndex(Index<String,E,Long> index)
Set the NDN index
|
void |
setObjectClassIndex(Index<String,E,Long> index)
Set the ObjectClass index
|
void |
setOneAliasIndex(Index<Long,E,Long> index)
Set the OneAlias index
|
void |
setOneLevelIndex(Index<Long,E,Long> index)
Set the OneLevel index
|
void |
setPresenceIndex(Index<String,E,Long> index)
Set the Presence index
|
void |
setProperty(String propertyName,
String propertyValue) |
void |
setSchemaManager(org.apache.directory.shared.ldap.schema.SchemaManager schemaManager) |
void |
setSubAliasIndex(Index<Long,E,Long> index)
Set the SubAlias index
|
void |
setSubLevelIndex(Index<Long,E,Long> index)
Set the SubLevel index
|
void |
setSuffixDn(String suffixDn) |
void |
setSyncOnWrite(boolean isSyncOnWrite)
Sets the flag telling the server to flush on disk when some
modification has been done.
|
void |
setUpdnIndex(Index<String,E,Long> index)
Set the UpDn index
|
void |
setUserIndices(Set<Index<?,E,Long>> userIndices)
Stores the list of user index
|
void |
setWorkingDirectory(File workingDirectory)
Sets the working directory for the store
|
void |
sync()
This method is called when the synch thread is waking up, to write
the modified data.
|
Iterator<String> |
systemIndices()
An iterator build on top of the System's index
|
Iterator<String> |
userIndices()
An iterator build on top of the User's index
|
public void setWorkingDirectory(File workingDirectory)
StoresetWorkingDirectory in interface Store<E,Long>public File getWorkingDirectory()
getWorkingDirectory in interface Store<E,Long>public void setSuffixDn(String suffixDn)
setSuffixDn in interface Store<E,Long>public String getSuffixDn()
getSuffixDn in interface Store<E,Long>public void setSyncOnWrite(boolean isSyncOnWrite)
StoresetSyncOnWrite in interface Store<E,Long>isSyncOnWrite - A boolean set to true if we have to flush on disk
when a modification occurspublic boolean isSyncOnWrite()
isSyncOnWrite in interface Store<E,Long>true if we write to disk for every modificationpublic void setCacheSize(int cacheSize)
StoresetCacheSize in interface Store<E,Long>cacheSize - The cache sizepublic int getCacheSize()
getCacheSize in interface Store<E,Long>public void setName(String name)
Storepublic String getName()
public Long getDefaultId()
StoregetDefaultId in interface Store<E,Long>public void init(org.apache.directory.shared.ldap.schema.SchemaManager schemaManager)
throws Exception
public void destroy()
throws Exception
public boolean isInitialized()
isInitialized in interface Store<E,Long>public void sync()
throws Exception
public void setUserIndices(Set<Index<?,E,Long>> userIndices)
StoresetUserIndices in interface Store<E,Long>userIndices - The list of user indexpublic Set<Index<?,E,Long>> getUserIndices()
getUserIndices in interface Store<E,Long>public void addIndex(Index<?,E,Long> index) throws Exception
Storepublic Index<String,E,Long> getPresenceIndex()
getPresenceIndex in interface Store<E,Long>public void setPresenceIndex(Index<String,E,Long> index) throws Exception
setPresenceIndex in interface Store<E,Long>index - The Presence indexException - If the addition failedpublic Index<Long,E,Long> getOneLevelIndex()
getOneLevelIndex in interface Store<E,Long>public void setOneLevelIndex(Index<Long,E,Long> index) throws Exception
setOneLevelIndex in interface Store<E,Long>index - The OneLevel indexException - If the addition failedpublic Index<String,E,Long> getAliasIndex()
getAliasIndex in interface Store<E,Long>public void setAliasIndex(Index<String,E,Long> index) throws org.apache.directory.shared.ldap.exception.LdapException
setAliasIndex in interface Store<E,Long>index - The Alias indexorg.apache.directory.shared.ldap.exception.LdapExceptionpublic Index<Long,E,Long> getOneAliasIndex()
getOneAliasIndex in interface Store<E,Long>public void setOneAliasIndex(Index<Long,E,Long> index) throws org.apache.directory.shared.ldap.exception.LdapException
setOneAliasIndex in interface Store<E,Long>index - The OneAlias indexorg.apache.directory.shared.ldap.exception.LdapExceptionpublic Index<Long,E,Long> getSubAliasIndex()
getSubAliasIndex in interface Store<E,Long>public void setSubAliasIndex(Index<Long,E,Long> index) throws org.apache.directory.shared.ldap.exception.LdapException
setSubAliasIndex in interface Store<E,Long>index - The SubAlias indexorg.apache.directory.shared.ldap.exception.LdapExceptionpublic Index<String,E,Long> getUpdnIndex()
getUpdnIndex in interface Store<E,Long>public void setUpdnIndex(Index<String,E,Long> index) throws org.apache.directory.shared.ldap.exception.LdapException
setUpdnIndex in interface Store<E,Long>index - The UpDn indexorg.apache.directory.shared.ldap.exception.LdapExceptionpublic Index<String,E,Long> getNdnIndex()
getNdnIndex in interface Store<E,Long>public void setNdnIndex(Index<String,E,Long> index) throws org.apache.directory.shared.ldap.exception.LdapException
setNdnIndex in interface Store<E,Long>index - The NDN indexorg.apache.directory.shared.ldap.exception.LdapExceptionpublic Index<Long,E,Long> getSubLevelIndex()
getSubLevelIndex in interface Store<E,Long>public void setSubLevelIndex(Index<Long,E,Long> index) throws org.apache.directory.shared.ldap.exception.LdapException
setSubLevelIndex in interface Store<E,Long>index - The SubLevel indexorg.apache.directory.shared.ldap.exception.LdapExceptionpublic Index<String,E,Long> getObjectClassIndex()
getObjectClassIndex in interface Store<E,Long>public void setObjectClassIndex(Index<String,E,Long> index) throws org.apache.directory.shared.ldap.exception.LdapException
setObjectClassIndex in interface Store<E,Long>index - The ObjectClass indexorg.apache.directory.shared.ldap.exception.LdapExceptionpublic Index<String,E,Long> getEntryUuidIndex()
getEntryUuidIndex in interface Store<E,Long>public void setEntryUuidIndex(Index<String,E,Long> index) throws org.apache.directory.shared.ldap.exception.LdapException
setEntryUuidIndex in interface Store<E,Long>index - The EntryUUID indexorg.apache.directory.shared.ldap.exception.LdapExceptionpublic Index<String,E,Long> getEntryCsnIndex()
getEntryCsnIndex in interface Store<E,Long>public void setEntryCsnIndex(Index<String,E,Long> index) throws org.apache.directory.shared.ldap.exception.LdapException
setEntryCsnIndex in interface Store<E,Long>index - The EntryCSN indexorg.apache.directory.shared.ldap.exception.LdapExceptionpublic Iterator<String> userIndices()
StoreuserIndices in interface Store<E,Long>public Iterator<String> systemIndices()
StoresystemIndices in interface Store<E,Long>public boolean hasIndexOn(String id) throws org.apache.directory.shared.ldap.exception.LdapException
StorehasIndexOn in interface Store<E,Long>id - The index we are looking fortrue if the index is already present in the
User's or System's index listorg.apache.directory.shared.ldap.exception.LdapExceptionpublic boolean hasUserIndexOn(String id) throws org.apache.directory.shared.ldap.exception.LdapException
StorehasUserIndexOn in interface Store<E,Long>id - The index we are looking fortrue if the index is already present in the
User's index listorg.apache.directory.shared.ldap.exception.LdapExceptionpublic boolean hasSystemIndexOn(String id) throws org.apache.directory.shared.ldap.exception.LdapException
StorehasSystemIndexOn in interface Store<E,Long>id - The index we are looking fortrue if the index is already present in the
System's index listorg.apache.directory.shared.ldap.exception.LdapExceptionpublic Index<?,E,Long> getIndex(String id) throws IndexNotFoundException
StoregetIndex in interface Store<E,Long>id - The index name we are looking forIndexNotFoundException - If the index does not existpublic Index<?,E,Long> getUserIndex(String id) throws IndexNotFoundException
StoregetUserIndex in interface Store<E,Long>id - The index name we are looking forIndexNotFoundException - If the index does not existpublic Index<?,E,Long> getSystemIndex(String id) throws IndexNotFoundException
StoregetSystemIndex in interface Store<E,Long>id - The index name we are looking forIndexNotFoundException - If the index does not existpublic Long getEntryId(String dn) throws Exception
getEntryId in interface Store<E,Long>Exceptionpublic String getEntryDn(Long id) throws Exception
getEntryDn in interface Store<E,Long>Exceptionpublic Long getParentId(String dn) throws Exception
getParentId in interface Store<E,Long>dn - the normalized distinguished name of the childException - on failures to access the underlying storepublic Long getParentId(Long childId) throws Exception
getParentId in interface Store<E,Long>Exceptionpublic String getEntryUpdn(Long id) throws Exception
getEntryUpdn in interface Store<E,Long>Exceptionpublic String getEntryUpdn(String dn) throws Exception
getEntryUpdn in interface Store<E,Long>Exceptionpublic int count()
throws Exception
public void add(org.apache.directory.shared.ldap.entry.ServerEntry entry)
throws Exception
public IndexCursor<Long,E,Long> list(Long id) throws Exception
public int getChildCount(Long id) throws Exception
getChildCount in interface Store<E,Long>Exceptionpublic org.apache.directory.shared.ldap.name.DN getSuffix()
public org.apache.directory.shared.ldap.name.DN getUpSuffix()
getUpSuffix in interface Store<E,Long>public void setProperty(String propertyName, String propertyValue) throws Exception
setProperty in interface Store<E,Long>Exceptionpublic String getProperty(String propertyName) throws Exception
getProperty in interface Store<E,Long>Exceptionpublic void modify(org.apache.directory.shared.ldap.name.DN dn,
org.apache.directory.shared.ldap.entry.ModificationOperation modOp,
org.apache.directory.shared.ldap.entry.ServerEntry mods)
throws Exception
public void modify(org.apache.directory.shared.ldap.name.DN dn,
List<org.apache.directory.shared.ldap.entry.Modification> mods)
throws Exception
public void rename(org.apache.directory.shared.ldap.name.DN dn,
org.apache.directory.shared.ldap.name.RDN newRdn,
boolean deleteOldRdn)
throws Exception
public void move(org.apache.directory.shared.ldap.name.DN oldChildDn,
org.apache.directory.shared.ldap.name.DN newParentDn,
org.apache.directory.shared.ldap.name.RDN newRdn,
boolean deleteOldRdn)
throws Exception
public void move(org.apache.directory.shared.ldap.name.DN oldChildDn,
org.apache.directory.shared.ldap.name.DN newParentDn)
throws Exception
public void setSchemaManager(org.apache.directory.shared.ldap.schema.SchemaManager schemaManager)
schemaManager - the schemaManager to setCopyright © 2003-2012 Apache Software Foundation. All Rights Reserved.