static String serializeNodeValue(Object value){
  String strValue;
  if (value == null) {
    strValue=null;
  }
 else   if (value instanceof Boolean) {
    strValue=XMPUtils.convertFromBoolean((boolean)value);
  }
 else   if (value instanceof Integer) {
    strValue=XMPUtils.convertFromInteger((int)value);
  }
 else   if (value instanceof Long) {
    strValue=XMPUtils.convertFromLong((long)value);
  }
 else   if (value instanceof Double) {
    strValue=XMPUtils.convertFromDouble((double)value);
  }
 else   if (value instanceof XMPDateTime) {
    strValue=XMPUtils.convertFromDate((XMPDateTime)value);
  }
 else   if (value instanceof GregorianCalendar) {
    XMPDateTime dt=XMPDateTimeFactory.createFromCalendar((GregorianCalendar)value);
    strValue=XMPUtils.convertFromDate(dt);
  }
 else   if (value instanceof byte[]) {
    strValue=XMPUtils.encodeBase64((byte[])value);
  }
 else {
    strValue=value.toString();
  }
  return strValue != null ? Utils.removeControlChars(strValue) : null;
}

static String serializeNodeValue ( Object value ) { String strValue ; if ( value == null ) { strValue = null ; } else if ( value instanceof Boolean ) { strValue = XMPUtils . convertFromBoolean ( ( boolean ) value ) ; } else if ( value instanceof Integer ) { strValue = XMPUtils . convertFromInteger ( ( int ) value ) ; } else if ( value instanceof Long ) { strValue = XMPUtils . convertFromLong ( ( long ) value ) ; } else if ( value instanceof Double ) { strValue = XMPUtils . convertFromDouble ( ( double ) value ) ; } else if ( value instanceof XMPDateTime ) { strValue = XMPUtils . convertFromDate ( ( XMPDateTime ) value ) ; } else if ( value instanceof GregorianCalendar ) { XMPDateTime dt = XMPDateTimeFactory . createFromCalendar ( ( GregorianCalendar ) value ) ; strValue = XMPUtils . convertFromDate ( dt ) ; } else if ( value instanceof byte [ ] ) { strValue = XMPUtils . encodeBase64 ( ( byte [ ] ) value ) ; } else { strValue = value . toString ( ) ; } return strValue != null ? Utils . removeControlChars ( strValue ) : null ; }
converts the node value to string , apply special conversions for defined types in xmp .
