Package com.isode.dsapi.config
Enum Class ChainPolicy
- All Implemented Interfaces:
Serializable
,Comparable<ChainPolicy>
,Constable
Isode chain policy.
- Since:
- 15.0
- Author:
- mv
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionDSP onlyDSP preferredLDAP onlyLDAP preferredNo chaining -
Method Summary
Modifier and TypeMethodDescriptiongetDbStr()
Returns the description stored for the enumeration.static ChainPolicy
getPolicy
(int index) Convert index to enum.static ChainPolicy
Convert DB string to enum.toString()
Returns the user-friendly name stored for the enumeration.static ChainPolicy
Returns the enum constant of this class with the specified name.static ChainPolicy[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
NO_CHAINING
No chaining -
LDAP
LDAP only -
DSP
DSP only -
LDAP_THEN_DSP
LDAP preferred -
DSP_THEN_LDAP
DSP preferred
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-
getPolicy
Convert DB string to enum. If it does not match any chaining policy,NO_CHAINING
is returned.- Parameters:
dbStr
- String indicating policy in the DB, a null value corresponds toNO_CHAINING
- Returns:
- corresponding enum value, will not be null
-
getPolicy
Convert index to enum.- Parameters:
index
- integer indicating policy index- Returns:
- corresponding enum value,
NO_CHAINING
if does not match any policy
-
userFriendlyStr
Returns the user-friendly name stored for the enumeration.- Returns:
- non-null friendly string for the enum
-
getDescription
Returns the description stored for the enumeration.- Returns:
- non-null description string for the enum
-
getDbStr
- Returns:
- DB string for the enumeration, will be null for
NO_CHAINING
-
toString
- Overrides:
toString
in classEnum<ChainPolicy>
-