Package com.netscape.cmscore.dbs
Class BigIntegerMapper
- java.lang.Object
-
- com.netscape.cmscore.dbs.BigIntegerMapper
-
- All Implemented Interfaces:
IDBAttrMapper
public class BigIntegerMapper extends java.lang.Object implements IDBAttrMapper
A class represents ann attribute mapper that maps a Java BigInteger object into LDAP attribute, and vice versa.- Version:
- $Revision$, $Date$
- Author:
- thomask
-
-
Constructor Summary
Constructors Constructor Description BigIntegerMapper(java.lang.String ldapName)Constructs BigInteger mapper.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static java.math.BigIntegerBigIntegerFromDB(java.lang.String i)static java.lang.StringBigIntegerToDB(java.math.BigInteger i)java.util.Enumeration<java.lang.String>getSupportedLDAPAttributeNames()Returns a list of supported ldap attribute names.voidmapLDAPAttributeSetToObject(netscape.ldap.LDAPAttributeSet attrs, java.lang.String name, IDBObj parent)Maps LDAP attributes into object, and put the object into 'parent'.voidmapObjectToLDAPAttributeSet(IDBObj parent, java.lang.String name, java.lang.Object obj, netscape.ldap.LDAPAttributeSet attrs)Maps object into ldap attribute set.java.lang.StringmapSearchFilter(java.lang.String name, java.lang.String op, java.lang.String value)Maps search filters into LDAP search filter.
-
-
-
Method Detail
-
getSupportedLDAPAttributeNames
public java.util.Enumeration<java.lang.String> getSupportedLDAPAttributeNames()
Returns a list of supported ldap attribute names.- Specified by:
getSupportedLDAPAttributeNamesin interfaceIDBAttrMapper- Returns:
- a list of supported attribute names
-
mapObjectToLDAPAttributeSet
public void mapObjectToLDAPAttributeSet(IDBObj parent, java.lang.String name, java.lang.Object obj, netscape.ldap.LDAPAttributeSet attrs) throws EBaseException
Maps object into ldap attribute set.- Specified by:
mapObjectToLDAPAttributeSetin interfaceIDBAttrMapper- Parameters:
parent- parent object where the object comes fromname- name of db attributeobj- object itselfattrs- LDAP attribute set where the result should be stored- Throws:
EBaseException- failed to map object
-
mapLDAPAttributeSetToObject
public void mapLDAPAttributeSetToObject(netscape.ldap.LDAPAttributeSet attrs, java.lang.String name, IDBObj parent) throws EBaseExceptionMaps LDAP attributes into object, and put the object into 'parent'.- Specified by:
mapLDAPAttributeSetToObjectin interfaceIDBAttrMapper- Parameters:
attrs- LDAP attribute setname- name of db attribute to be processedparent- parent object where the object should be added- Throws:
EBaseException- failed to map object
-
mapSearchFilter
public java.lang.String mapSearchFilter(java.lang.String name, java.lang.String op, java.lang.String value) throws EBaseExceptionMaps search filters into LDAP search filter.- Specified by:
mapSearchFilterin interfaceIDBAttrMapper- Parameters:
name- name of db attributeop- filte operation (i.e. "=", ">=")value- attribute value- Throws:
EBaseException- failed to map filter
-
BigIntegerToDB
public static java.lang.String BigIntegerToDB(java.math.BigInteger i)
-
BigIntegerFromDB
public static java.math.BigInteger BigIntegerFromDB(java.lang.String i)
-
-