Interface ComparatorRegistry
-
- All Superinterfaces:
Iterable<LdapComparator<?>>
,SchemaObjectRegistry<LdapComparator<?>>
- All Known Implementing Classes:
DefaultComparatorRegistry
,ImmutableComparatorRegistry
public interface ComparatorRegistry extends SchemaObjectRegistry<LdapComparator<?>>, Iterable<LdapComparator<?>>
Comparator registry component's service class.- Author:
- Apache Directory Project
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description ComparatorRegistry
copy()
Copy the ComparatorRegistryvoid
register(LdapComparator<?> comparator)
Registers a new LdapComparator with this registry.LdapComparator<?>
unregister(String numericOid)
Removes the LdapComparator registered with this registry, using its numeric OID.void
unregisterSchemaElements(String schemaName)
Unregisters all LdapComparators defined for a specific schema from this registry.-
Methods inherited from interface java.lang.Iterable
forEach, iterator, spliterator
-
Methods inherited from interface org.apache.directory.api.ldap.model.schema.registries.SchemaObjectRegistry
clear, contains, get, getOidByName, getSchemaName, getType, iterator, lookup, oidsIterator, renameSchema, size, unregister
-
-
-
-
Method Detail
-
register
void register(LdapComparator<?> comparator) throws LdapException
Registers a new LdapComparator with this registry.- Specified by:
register
in interfaceSchemaObjectRegistry<LdapComparator<?>>
- Parameters:
comparator
- the LdapComparator to register- Throws:
LdapException
- if the LdapComparator is already registered or the registration operation is not supported
-
unregister
LdapComparator<?> unregister(String numericOid) throws LdapException
Removes the LdapComparator registered with this registry, using its numeric OID.- Specified by:
unregister
in interfaceSchemaObjectRegistry<LdapComparator<?>>
- Parameters:
numericOid
- the numeric identifier- Returns:
- The unregistred schema object
- Throws:
LdapException
- if the numeric identifier is invalid
-
unregisterSchemaElements
void unregisterSchemaElements(String schemaName) throws LdapException
Unregisters all LdapComparators defined for a specific schema from this registry.- Specified by:
unregisterSchemaElements
in interfaceSchemaObjectRegistry<LdapComparator<?>>
- Parameters:
schemaName
- the name of the schema whose LdapComparators will be removed from- Throws:
LdapException
- If we had a problem while unregistering the schema
-
copy
ComparatorRegistry copy()
Copy the ComparatorRegistry- Specified by:
copy
in interfaceSchemaObjectRegistry<LdapComparator<?>>
- Returns:
- The copied registry
-
-