public static final String printExtendedAttribute ( MSPDIWriter writer , Object value , DataType type ) { String result ; if ( type == DataType . DATE ) { result = printExtendedAttributeDate ( ( Date ) value ) ; } else { if ( value instanceof Boolean ) { result = printExtendedAttributeBoolean ( ( Boolean ) value ) ; } else { if ( value instanceof Duration ) { result = printDuration ( writer , ( Duration ) value ) ; } else { if ( type == DataType . CURRENCY ) { result = printExtendedAttributeCurrency ( ( Number ) value ) ; } else { if ( value instanceof Number ) { result = printExtendedAttributeNumber ( ( Number ) value ) ; } else { result = value . toString ( ) ; } } } } } return ( result ) ; }
Print an extended attribute value .