Package edu.vt.middleware.ldap.dsml
Class DsmlResultConverter
- java.lang.Object
-
- edu.vt.middleware.ldap.dsml.DsmlResultConverter
-
public class DsmlResultConverter extends java.lang.Object
DsmlResultConverter
provides utility methods for convertingLdapResult
to and from DSML in string format.- Version:
- $Revision: 1330 $ $Date: 2010-05-24 00:10:53 +0200 (Mon, 24 May 2010) $
- Author:
- Middleware Services
-
-
Field Summary
Fields Modifier and Type Field Description protected LdapBeanFactory
beanFactory
Ldap bean factory.protected org.apache.commons.logging.Log
logger
Log for this class.
-
Constructor Summary
Constructors Constructor Description DsmlResultConverter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description LdapResult
fromDsmlv1(java.lang.String dsml)
This reads any entries in the supplied DSML into thisDsmlResult
.LdapResult
fromDsmlv2(java.lang.String dsml)
This reads any entries in the supplied DSML into thisDsmlResult
.LdapBeanFactory
getLdapBeanFactory()
Returns the factory for creating ldap beans.void
setLdapBeanFactory(LdapBeanFactory lbf)
Sets the factory for creating ldap beans.java.lang.String
toDsmlv1(LdapResult result)
This returns thisDsmlResult
as version 1 DSML.java.lang.String
toDsmlv2(LdapResult result)
This returns thisDsmlResult
as version 2 DSML.
-
-
-
Field Detail
-
logger
protected final org.apache.commons.logging.Log logger
Log for this class.
-
beanFactory
protected LdapBeanFactory beanFactory
Ldap bean factory.
-
-
Method Detail
-
getLdapBeanFactory
public LdapBeanFactory getLdapBeanFactory()
Returns the factory for creating ldap beans.- Returns:
LdapBeanFactory
-
setLdapBeanFactory
public void setLdapBeanFactory(LdapBeanFactory lbf)
Sets the factory for creating ldap beans.- Parameters:
lbf
-LdapBeanFactory
-
toDsmlv1
public java.lang.String toDsmlv1(LdapResult result)
This returns thisDsmlResult
as version 1 DSML.- Parameters:
result
-LdapResult
to convert- Returns:
String
-
fromDsmlv1
public LdapResult fromDsmlv1(java.lang.String dsml) throws org.dom4j.DocumentException
This reads any entries in the supplied DSML into thisDsmlResult
.- Parameters:
dsml
-String
to read- Returns:
LdapResult
- Throws:
org.dom4j.DocumentException
- if an error occurs reading the supplied DSML
-
toDsmlv2
public java.lang.String toDsmlv2(LdapResult result)
This returns thisDsmlResult
as version 2 DSML.- Parameters:
result
-LdapResult
to convert- Returns:
String
-
fromDsmlv2
public LdapResult fromDsmlv2(java.lang.String dsml) throws org.dom4j.DocumentException
This reads any entries in the supplied DSML into thisDsmlResult
.- Parameters:
dsml
-String
to read- Returns:
LdapResult
- Throws:
org.dom4j.DocumentException
- if an error occurs reading the supplied DSML
-
-