|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.ca.jcs.cfg.Vetoable
com.ca.jcs.converter.meta.ClassConverter
com.ca.jcs.converter.meta.JSONCompoundValueClassConverter
public class JSONCompoundValueClassConverter
Converts JNDI Attributes collections representing compound values to/from JSON objects, or
optionally their string representation. When used directly this class performs no LDAP-speak <=> connector-speak attribute id mapping, but when
its protected methods are invoked via JSONReverseCompoundValueClassConverter this mapping is performed as part of the conversion process.
| Nested Class Summary | |
|---|---|
static class |
JSONCompoundValueClassConverter.Config
|
| Field Summary |
|---|
| Fields inherited from class com.ca.jcs.converter.meta.ClassConverter |
|---|
classMap, converterConfig |
| Constructor Summary | |
|---|---|
JSONCompoundValueClassConverter(JSONCompoundValueClassConverter.Config cfg,
MetaObjectClassMapping classMap)
|
|
JSONCompoundValueClassConverter(MetaObjectClassMapping classMap)
|
|
| Method Summary | |
|---|---|
void |
convertFromConnector(Attributes attrs)
Flat Attributes (JSON values) => Attributes(maybe nested), with no attrId mapping. |
protected Attribute |
convertPropertyFromJSON(MetaObjectClassMapping classMap,
DataModelProperty dmProp,
boolean isLdap,
boolean mapAttrIds,
com.ca.commons.json.JSONValue jsonVal)
|
void |
convertToConnector(Attributes attrs)
Attributes (maybe nested) => Attributes(JSON values). |
ModificationItem[] |
convertToConnector(ModificationItem[] modItems)
Attributes (maybe nested) => Attributes(JSON values). |
protected void |
doConvertFromConnector(Attributes attrs,
boolean isLdap,
boolean mapAttrIds)
Note top-level ids in attrs are always in LDAP-speak, regardless of the value of isLdap. |
protected void |
doConvertToConnector(Attributes attrs,
boolean isLdap,
boolean mapAttrIds)
Add flag which controls attribute id mapping in nested compound values. |
boolean |
isStructural()
Returns true if the converter performs a change to the structure of an attribute's values, rather then just transforming individual values themselves. |
static com.ca.commons.json.JSONValue |
parseJSON(String s)
|
| Methods inherited from class com.ca.jcs.cfg.Vetoable |
|---|
isVetoed, setVetoed |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public JSONCompoundValueClassConverter(JSONCompoundValueClassConverter.Config cfg,
MetaObjectClassMapping classMap)
public JSONCompoundValueClassConverter(MetaObjectClassMapping classMap)
| Method Detail |
|---|
public boolean isStructural()
ClassConverter
isStructural in class ClassConverter
protected void doConvertToConnector(Attributes attrs,
boolean isLdap,
boolean mapAttrIds)
throws NamingException
NamingException
public void convertToConnector(Attributes attrs)
throws NamingException
convertToConnector in class ClassConverterNamingException
public ModificationItem[] convertToConnector(ModificationItem[] modItems)
throws NamingException
convertToConnector in class ClassConverterNamingException
protected Attribute convertPropertyFromJSON(MetaObjectClassMapping classMap,
DataModelProperty dmProp,
boolean isLdap,
boolean mapAttrIds,
com.ca.commons.json.JSONValue jsonVal)
throws NamingException
NamingException
@NotNull
public static com.ca.commons.json.JSONValue parseJSON(String s)
throws NamingException
NamingException
protected void doConvertFromConnector(Attributes attrs,
boolean isLdap,
boolean mapAttrIds)
throws NamingException
NamingException
public void convertFromConnector(Attributes attrs)
throws NamingException
convertFromConnector in class ClassConverterNamingException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||