org.apache.directory.shared.ldap.message
Class DerefAliasesEnum

java.lang.Object
  extended byorg.apache.directory.shared.ldap.util.Enum
      extended byorg.apache.directory.shared.ldap.util.ValuedEnum
          extended byorg.apache.directory.shared.ldap.message.DerefAliasesEnum
All Implemented Interfaces:
java.lang.Comparable, java.io.Serializable

public class DerefAliasesEnum
extends ValuedEnum

Type-safe derefAliases search parameter enumeration which determines the mode of alias handling. Note that the names of these ValuedEnums correspond to the value for the java.naming.ldap.derefAliases JNDI LDAP specific property.

Version:
$Revision: 379008 $
Author:
Alex Karasulu, $Author: akarasulu $
See Also:
Serialized Form

Field Summary
static DerefAliasesEnum DEREFALWAYS
          Alias handling mode that dereferences always
static java.lang.String DEREFALWAYS_NAME
          Alias handling mode name that dereferences always
static int DEREFALWAYS_VAL
          Alias handling mode value that dereferences always
static DerefAliasesEnum DEREFFINDINGBASEOBJ
          Alias handling mode that dereferences only in finding the base
static java.lang.String DEREFFINDINGBASEOBJ_NAME
          Alias handling mode name that dereferences only in finding the base
static int DEREFFINDINGBASEOBJ_VAL
          Alias handling mode value that dereferences only in finding the base
static DerefAliasesEnum DEREFINSEARCHING
          Alias handling mode that dereferences only when searching
static java.lang.String DEREFINSEARCHING_NAME
          Alias handling mode name that dereferences only when searching
static int DEREFINSEARCHING_VAL
          Alias handling mode value that dereferences only when searching
static java.lang.String JNDI_PROP
          java.naming.ldap.derefAliases JNDI property
static DerefAliasesEnum NEVERDEREFALIASES
          Alias handling mode that treats aliases like entries
static java.lang.String NEVERDEREFALIASES_NAME
          Alias handling mode name that treats aliases like entries
static int NEVERDEREFALIASES_VAL
          Alias handling mode value that treats aliases like entries
 
Fields inherited from class org.apache.directory.shared.ldap.util.Enum
iToString
 
Method Summary
 boolean derefAlways()
          Checks to see if we dereference while searching and finding the base.
 boolean derefFindingBase()
          Checks to see if we dereference while finding the base.
 boolean derefInSearching()
          Checks to see if we dereference while searching.
static DerefAliasesEnum getEnum(java.util.Map env)
          Gets the enumeration from by extracting the value for the JNDI LDAP specific environment property, java.naming.ldap.derefAliases, from the environment.
static DerefAliasesEnum getEnum(java.lang.String a_name)
          Gets the enumeration for a enumeration name which also happens to be the value of the java.naming.ldap.derefAliases LDAP proovider property.
 boolean neverDeref()
          Checks to see if we never dereference aliases.
 
Methods inherited from class org.apache.directory.shared.ldap.util.ValuedEnum
compareTo, getEnum, getValue, toString
 
Methods inherited from class org.apache.directory.shared.ldap.util.Enum
equals, getEnum, getEnumClass, getEnumList, getEnumMap, getName, hashCode, iterator, readResolve
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

JNDI_PROP

public static final java.lang.String JNDI_PROP
java.naming.ldap.derefAliases JNDI property

See Also:
Constant Field Values

NEVERDEREFALIASES_NAME

public static final java.lang.String NEVERDEREFALIASES_NAME
Alias handling mode name that treats aliases like entries

See Also:
Constant Field Values

DEREFINSEARCHING_NAME

public static final java.lang.String DEREFINSEARCHING_NAME
Alias handling mode name that dereferences only when searching

See Also:
Constant Field Values

DEREFFINDINGBASEOBJ_NAME

public static final java.lang.String DEREFFINDINGBASEOBJ_NAME
Alias handling mode name that dereferences only in finding the base

See Also:
Constant Field Values

DEREFALWAYS_NAME

public static final java.lang.String DEREFALWAYS_NAME
Alias handling mode name that dereferences always

See Also:
Constant Field Values

NEVERDEREFALIASES_VAL

public static final int NEVERDEREFALIASES_VAL
Alias handling mode value that treats aliases like entries

See Also:
Constant Field Values

DEREFINSEARCHING_VAL

public static final int DEREFINSEARCHING_VAL
Alias handling mode value that dereferences only when searching

See Also:
Constant Field Values

DEREFFINDINGBASEOBJ_VAL

public static final int DEREFFINDINGBASEOBJ_VAL
Alias handling mode value that dereferences only in finding the base

See Also:
Constant Field Values

DEREFALWAYS_VAL

public static final int DEREFALWAYS_VAL
Alias handling mode value that dereferences always

See Also:
Constant Field Values

NEVERDEREFALIASES

public static final DerefAliasesEnum NEVERDEREFALIASES
Alias handling mode that treats aliases like entries


DEREFINSEARCHING

public static final DerefAliasesEnum DEREFINSEARCHING
Alias handling mode that dereferences only when searching


DEREFFINDINGBASEOBJ

public static final DerefAliasesEnum DEREFFINDINGBASEOBJ
Alias handling mode that dereferences only in finding the base


DEREFALWAYS

public static final DerefAliasesEnum DEREFALWAYS
Alias handling mode that dereferences always

Method Detail

derefAlways

public boolean derefAlways()
Checks to see if we dereference while searching and finding the base.

Returns:
true if value is DEREFALWAYS_VAL, false otherwise

neverDeref

public boolean neverDeref()
Checks to see if we never dereference aliases.

Returns:
true if value is NEVERDEREFALIASES_VAL, false otherwise

derefInSearching

public boolean derefInSearching()
Checks to see if we dereference while searching.

Returns:
true if value is DEREFALWAYS_VAL, or DEREFINSEARCHING_VAL, and false otherwise.

derefFindingBase

public boolean derefFindingBase()
Checks to see if we dereference while finding the base.

Returns:
true if value is DEREFALWAYS_VAL, or DEREFFINDINGBASEOBJ_VAL, and false otherwise.

getEnum

public static DerefAliasesEnum getEnum(java.lang.String a_name)
Gets the enumeration for a enumeration name which also happens to be the value of the java.naming.ldap.derefAliases LDAP proovider property.

Parameters:
a_name - the value for the java.naming.ldap.derefAliases or a name of an enum value.
Returns:
the enumeration for a name

getEnum

public static DerefAliasesEnum getEnum(java.util.Map env)
Gets the enumeration from by extracting the value for the JNDI LDAP specific environment property, java.naming.ldap.derefAliases, from the environment.

Parameters:
env - the JNDI environment with a potential value for the java.naming.ldap.derefAliases property
Returns:
the enumeration for the environment


Copyright © 2003-2006 . All Rights Reserved.