org.apache.directory.server.core.schema
Class GlobalMatchingRuleUseRegistry

java.lang.Object
  extended by org.apache.directory.server.core.schema.GlobalMatchingRuleUseRegistry
All Implemented Interfaces:
MatchingRuleUseRegistry

public class GlobalMatchingRuleUseRegistry
extends java.lang.Object
implements MatchingRuleUseRegistry

A plain old java object implementation of an MatchingRuleUseRegistry.

Version:
$Rev: 434579 $
Author:
Apache Directory Project

Constructor Summary
GlobalMatchingRuleUseRegistry(BootstrapMatchingRuleUseRegistry bootstrap, OidRegistry oidRegistry)
          Creates an empty BootstrapMatchingRuleUseRegistry.
 
Method Summary
 java.lang.String getSchemaName(java.lang.String id)
          Gets the name of the schema this schema object is associated with.
 boolean hasMatchingRuleUse(java.lang.String id)
          Checks to see if an matchingRuleUse exists.
 java.util.Iterator list()
          Lists all the MatchingRuleUses within this registry.
 org.apache.directory.shared.ldap.schema.MatchingRuleUse lookup(java.lang.String id)
          Looks up an matchingRuleUse by its name.
 void register(java.lang.String schema, org.apache.directory.shared.ldap.schema.MatchingRuleUse dITContentRule)
          Registers a MatchingRuleUse with this registry.
 void setMonitor(MatchingRuleUseRegistryMonitor monitor)
          Sets the monitor that is to be notified via callback events.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GlobalMatchingRuleUseRegistry

public GlobalMatchingRuleUseRegistry(BootstrapMatchingRuleUseRegistry bootstrap,
                                     OidRegistry oidRegistry)
Creates an empty BootstrapMatchingRuleUseRegistry.

Method Detail

setMonitor

public void setMonitor(MatchingRuleUseRegistryMonitor monitor)
Sets the monitor that is to be notified via callback events.

Parameters:
monitor - the new monitor to notify of notable events

register

public void register(java.lang.String schema,
                     org.apache.directory.shared.ldap.schema.MatchingRuleUse dITContentRule)
              throws javax.naming.NamingException
Description copied from interface: MatchingRuleUseRegistry
Registers a MatchingRuleUse with this registry.

Specified by:
register in interface MatchingRuleUseRegistry
Parameters:
schema - the name of the schema the MatchingRuleUse is associated with
dITContentRule - the matchingRuleUse to register
Throws:
javax.naming.NamingException - if the MatchingRuleUse is already registered or the registration operation is not supported

lookup

public org.apache.directory.shared.ldap.schema.MatchingRuleUse lookup(java.lang.String id)
                                                               throws javax.naming.NamingException
Description copied from interface: MatchingRuleUseRegistry
Looks up an matchingRuleUse by its name.

Specified by:
lookup in interface MatchingRuleUseRegistry
Parameters:
id - the name of the matchingRuleUse
Returns:
the MatchingRuleUse instance for the name
Throws:
javax.naming.NamingException - if the MatchingRuleUse does not exist

hasMatchingRuleUse

public boolean hasMatchingRuleUse(java.lang.String id)
Description copied from interface: MatchingRuleUseRegistry
Checks to see if an matchingRuleUse exists.

Specified by:
hasMatchingRuleUse in interface MatchingRuleUseRegistry
Parameters:
id - the name of the matchingRuleUse
Returns:
true if an matchingRuleUse definition exists for the name, false otherwise

getSchemaName

public java.lang.String getSchemaName(java.lang.String id)
                               throws javax.naming.NamingException
Description copied from interface: MatchingRuleUseRegistry
Gets the name of the schema this schema object is associated with.

Specified by:
getSchemaName in interface MatchingRuleUseRegistry
Parameters:
id - the name String
Returns:
the schema name
Throws:
javax.naming.NamingException - if the schema object does not exist

list

public java.util.Iterator list()
Description copied from interface: MatchingRuleUseRegistry
Lists all the MatchingRuleUses within this registry.

Specified by:
list in interface MatchingRuleUseRegistry
Returns:
an Iterator over all the MatchingRuleUses within this registry


Copyright © 2003-2009 Apache Software Foundation. All Rights Reserved.