public abstract class AbstractRegistrySynchronizer extends Object implements RegistrySynchronizer
Modifier and Type | Field and Description |
---|---|
protected org.apache.directory.api.ldap.schema.loader.SchemaEntityFactory |
factory
The Schema objetc factory
|
protected org.apache.directory.api.ldap.model.schema.AttributeType |
moidAT
The m-oid AttributeType
|
protected org.apache.directory.api.ldap.model.schema.SchemaManager |
schemaManager
The global SchemaManager
|
SCHEMA_MODIFIED, SCHEMA_UNCHANGED
Modifier | Constructor and Description |
---|---|
protected |
AbstractRegistrySynchronizer(org.apache.directory.api.ldap.model.schema.SchemaManager schemaManager) |
Modifier and Type | Method and Description |
---|---|
protected void |
addToSchema(org.apache.directory.api.ldap.model.schema.SchemaObject schemaObject,
String schemaName)
Add a new SchemaObject to the schema content, assuming that
it has an associated schema and that this schema is loaded
|
protected org.apache.directory.api.ldap.model.schema.SchemaObject |
checkOidExists(org.apache.directory.api.ldap.model.entry.Entry entry)
Check that a SchemaObject exists in the global OidRegsitry, and if so,
return it.
|
protected void |
checkOidIsUnique(org.apache.directory.api.ldap.model.entry.Entry entry) |
protected void |
checkOidIsUnique(org.apache.directory.api.ldap.model.schema.SchemaObject schemaObject) |
protected void |
checkOidIsUnique(String oid) |
protected void |
checkParent(org.apache.directory.api.ldap.model.name.Dn newParent,
org.apache.directory.api.ldap.model.schema.SchemaManager schemaManager,
String objectType)
Checks that the parent Dn is a valid Dn
|
protected void |
deleteFromSchema(org.apache.directory.api.ldap.model.schema.SchemaObject schemaObject,
String schemaName)
Delete a SchemaObject from the schema registry, assuming that
it has an associated schema and that this schema is loaded
|
protected String |
getOid(org.apache.directory.api.ldap.model.entry.Entry entry) |
protected Set<String> |
getOids(Set<org.apache.directory.api.ldap.model.entry.Entry> results) |
protected String |
getReferenced(org.apache.directory.api.ldap.model.schema.SchemaObject schemaObject)
Get a String containing the SchemaObjects referencing the
given ShcemaObject
|
protected String |
getSchemaName(org.apache.directory.api.ldap.model.name.Dn dn)
Exctract the schema name from the Dn.
|
protected boolean |
isSchemaEnabled(String schemaName)
Tells if a schema is loaded and enabled
|
protected boolean |
isSchemaLoaded(org.apache.directory.api.ldap.model.name.Dn dn)
Tells if the schema the Dn references is loaded or not
|
protected boolean |
isSchemaLoaded(String schemaName)
Tells if the schemaName is loaded or not
|
protected void |
registerOids(org.apache.directory.api.ldap.model.schema.SchemaObject obj)
Register a SchemaObject's OID in the associated oidRegistry
|
protected void |
unregisterOids(org.apache.directory.api.ldap.model.schema.SchemaObject obj)
Unregister a SchemaObject's OID from the associated oidRegistry
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
add, delete, modify, move, moveAndRename, rename
protected final org.apache.directory.api.ldap.model.schema.SchemaManager schemaManager
protected final org.apache.directory.api.ldap.model.schema.AttributeType moidAT
protected final org.apache.directory.api.ldap.schema.loader.SchemaEntityFactory factory
protected AbstractRegistrySynchronizer(org.apache.directory.api.ldap.model.schema.SchemaManager schemaManager)
protected boolean isSchemaLoaded(org.apache.directory.api.ldap.model.name.Dn dn) throws org.apache.directory.api.ldap.model.exception.LdapException
dn
- The SchemaObject's Dnorg.apache.directory.api.ldap.model.exception.LdapException
- If The Dn is not a SchemaObject Dnprotected boolean isSchemaLoaded(String schemaName)
schemaName
- The schema we want to checkprotected boolean isSchemaEnabled(String schemaName)
schemaName
- The schema we want to checkprotected String getSchemaName(org.apache.directory.api.ldap.model.name.Dn dn) throws org.apache.directory.api.ldap.model.exception.LdapException
ou=schema, cn=MySchema, ...Here, the schemaName is MySchema
dn
- The Dn we want to get the schema name fromorg.apache.directory.api.ldap.model.exception.LdapException
- If we got an errorprotected void checkOidIsUnique(org.apache.directory.api.ldap.model.entry.Entry entry) throws org.apache.directory.api.ldap.model.exception.LdapException
org.apache.directory.api.ldap.model.exception.LdapException
protected org.apache.directory.api.ldap.model.schema.SchemaObject checkOidExists(org.apache.directory.api.ldap.model.entry.Entry entry) throws org.apache.directory.api.ldap.model.exception.LdapException
entry
- The Entry we want to verify the existence oforg.apache.directory.api.ldap.model.exception.LdapException
- If the check failedprotected void checkParent(org.apache.directory.api.ldap.model.name.Dn newParent, org.apache.directory.api.ldap.model.schema.SchemaManager schemaManager, String objectType) throws org.apache.directory.api.ldap.model.exception.LdapException
newParent
- The parent DN to checkschemaManager
- The SchemaManager instanceobjectType
- The ObjectType to checkorg.apache.directory.api.ldap.model.exception.LdapException
- If the deletion failedprotected void checkOidIsUnique(org.apache.directory.api.ldap.model.schema.SchemaObject schemaObject) throws org.apache.directory.api.ldap.model.exception.LdapException
org.apache.directory.api.ldap.model.exception.LdapException
protected void checkOidIsUnique(String oid) throws org.apache.directory.api.ldap.model.exception.LdapException
org.apache.directory.api.ldap.model.exception.LdapException
protected void addToSchema(org.apache.directory.api.ldap.model.schema.SchemaObject schemaObject, String schemaName) throws org.apache.directory.api.ldap.model.exception.LdapException
schemaObject
- The SchemaObject to addschemaName
- The Schema we want the SchemaObject to be added inorg.apache.directory.api.ldap.model.exception.LdapException
- If the addition failedprotected void deleteFromSchema(org.apache.directory.api.ldap.model.schema.SchemaObject schemaObject, String schemaName) throws org.apache.directory.api.ldap.model.exception.LdapException
schemaObject
- The SchemaObject to deleteschemaName
- The Schema we want the SchemaObject to be deleted fromorg.apache.directory.api.ldap.model.exception.LdapException
- If the deletion failedprotected String getOid(org.apache.directory.api.ldap.model.entry.Entry entry) throws org.apache.directory.api.ldap.model.exception.LdapException
org.apache.directory.api.ldap.model.exception.LdapException
protected void unregisterOids(org.apache.directory.api.ldap.model.schema.SchemaObject obj) throws org.apache.directory.api.ldap.model.exception.LdapException
obj
- The SchemaObject to unregisterorg.apache.directory.api.ldap.model.exception.LdapException
- If the unregistering failedprotected void registerOids(org.apache.directory.api.ldap.model.schema.SchemaObject obj) throws org.apache.directory.api.ldap.model.exception.LdapException
obj
- The SchemaObject to registerorg.apache.directory.api.ldap.model.exception.LdapException
- If the registering failedprotected String getReferenced(org.apache.directory.api.ldap.model.schema.SchemaObject schemaObject)
schemaObject
- The SchemaObject we want the referencing SchemaObjects forCopyright © 2003–2020 The Apache Software Foundation. All rights reserved.