com.ca.jcs.converter.attr
Class ORedMultiValueFlattener
java.lang.Object
com.ca.jcs.converter.attr.MultiValueFlattener
com.ca.jcs.converter.attr.ORedMultiValueFlattener
- All Implemented Interfaces:
- AttributeConverter
public class ORedMultiValueFlattener
- extends MultiValueFlattener
A Flattening converter that performs logical OR operation on multi-valued attribute
values which are numeric/enum ordinals.
In the to connector direction a logical OR is performed on all attribute values,
in the from connector direction the ORable values are sent in an order that may not
coincide to the one sent in originally due to the ORing process being partially lossy.
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
FLATTEN_STYLE
public static final String FLATTEN_STYLE
- See Also:
- Constant Field Values
ORedMultiValueFlattener
public ORedMultiValueFlattener(DataModelEnumDef enumDef,
Boolean isStoreNumeric)
getStyle
public String getStyle()
- Specified by:
getStyle in class MultiValueFlattener
writeEnd
protected void writeEnd(StringWriter writer)
- Specified by:
writeEnd in class MultiValueFlattener
writeStart
protected void writeStart(StringWriter writer)
- Specified by:
writeStart in class MultiValueFlattener
writeValue
protected void writeValue(StringWriter writer,
String value,
boolean firstValue)
- Flatten an attribute value via ORing.
For enum based properties, depending on whether EnumPropertyConverter
isn't already active on this property the input value sent will be a
symbolic name (isStoreSymbolic - not currently allowed) or an already
converted ordinal value (isStoreNumeric).
If Enum converter not active then a symbolic enum value is expected.
For numeric properties just a number is expected.
- Specified by:
writeValue in class MultiValueFlattener
convertFromConnector
public void convertFromConnector(Attribute connAttrVals)
throws NamingException
- Throws:
NamingException
Created 2011-07-14 13:27 EST