org.apache.directory.server.schema
Class NameAndOptionalUIDComparator

java.lang.Object
  extended by org.apache.directory.server.schema.NameAndOptionalUIDComparator
All Implemented Interfaces:
java.util.Comparator

public class NameAndOptionalUIDComparator
extends java.lang.Object
implements java.util.Comparator

A comparator for the uniqueMember match

Version:
$Rev$
Author:
Apache Directory Project

Constructor Summary
NameAndOptionalUIDComparator()
           
NameAndOptionalUIDComparator(AttributeTypeRegistry attrRegistry)
           
 
Method Summary
 int compare(java.lang.Object obj0, java.lang.Object obj1)
          Comparing two uniqueMember is a matter of following this algorithm: - if they are only DN, then the values should be equal - otherwise, both element should contain the same DN and * if they both have an UID, they should be equals.
 org.apache.directory.shared.ldap.name.LdapDN getDn(java.lang.Object obj)
           
 void setRegistries(Registries registries)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface java.util.Comparator
equals
 

Constructor Detail

NameAndOptionalUIDComparator

public NameAndOptionalUIDComparator(AttributeTypeRegistry attrRegistry)

NameAndOptionalUIDComparator

public NameAndOptionalUIDComparator()
Method Detail

setRegistries

public void setRegistries(Registries registries)

compare

public int compare(java.lang.Object obj0,
                   java.lang.Object obj1)
Comparing two uniqueMember is a matter of following this algorithm: - if they are only DN, then the values should be equal - otherwise, both element should contain the same DN and * if they both have an UID, they should be equals.

Specified by:
compare in interface java.util.Comparator

getDn

public org.apache.directory.shared.ldap.name.LdapDN getDn(java.lang.Object obj)
                                                   throws javax.naming.NamingException
Throws:
javax.naming.NamingException


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