org.apache.directory.shared.ldap.schema
Enum MatchingRuleEnum

java.lang.Object
  extended by java.lang.Enum<MatchingRuleEnum>
      extended by org.apache.directory.shared.ldap.schema.MatchingRuleEnum
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable<MatchingRuleEnum>

public enum MatchingRuleEnum
extends java.lang.Enum<MatchingRuleEnum>

Type safe enum for a matching rule's comparator and normalizer component usage string. This can be take one of the following three values:

Author:
Apache Directory Project

Enum Constant Summary
EQUALITY
          value for equality usage
ORDERING
          value for ordering usage
SUBSTRING
          value for substring usage
 
Method Summary
static MatchingRuleEnum getUsage(java.lang.String matchingRule)
          Gets the enumeration type for the usage string regardless of case.
 int getValue()
           
static MatchingRuleEnum valueOf(java.lang.String name)
          Returns the enum constant of this type with the specified name.
static MatchingRuleEnum[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

ORDERING

public static final MatchingRuleEnum ORDERING
value for ordering usage


EQUALITY

public static final MatchingRuleEnum EQUALITY
value for equality usage


SUBSTRING

public static final MatchingRuleEnum SUBSTRING
value for substring usage

Method Detail

values

public static MatchingRuleEnum[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
for (MatchingRuleEnum c : MatchingRuleEnum.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static MatchingRuleEnum valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
java.lang.NullPointerException - if the argument is null

getValue

public int getValue()
Returns:
The value associated with the current element.

getUsage

public static MatchingRuleEnum getUsage(java.lang.String matchingRule)
Gets the enumeration type for the usage string regardless of case.

Parameters:
matchingRule - the usage string
Returns:
the matchingRule enumeration type


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