Package org.apache.shiro.realm.ldap
Class LdapUtils
-
- org.apache.shiro.realm.ldap.LdapUtils
-
public final class LdapUtils extends
Utility class providing static methods to make working with LDAP easier.- Since:
- 0.2
-
-
Constructor Summary
Constructors Constructor Description LdapUtils()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static void
ctx)
Closes an LDAP context, logging any errors, but not throwing an exception if there is a failure.static void
ne)
static <>
attr)
Helper method used to retrieve all attribute values from a particular context attribute.
-
-
-
Method Detail
-
closeContext
public static void closeContext( ctx)
Closes an LDAP context, logging any errors, but not throwing an exception if there is a failure.- Parameters:
ctx
- the LDAP context to close.
-
getAllAttributeValues
public static <> getAllAttributeValues( attr) throws
Helper method used to retrieve all attribute values from a particular context attribute.- Parameters:
attr
- the LDAP attribute.- Returns:
- the values of the attribute.
- Throws:
- if there is an LDAP error while reading the values.
-
closeEnumeration
public static void closeEnumeration( ne)
-
-