TypeConverter getConverter(String attributeName) {
        Object attributeValue = getAttributeValue(attributeName);
        if (attributeValue == null) {
            return NULL_CONVERTER;
        } else if (attributeValue instanceof MultiResult) {
            MultiResult multiResult = (MultiResult) attributeValue;
            for (Object result : multiResult.getResults()) {
                if (result != null) {
                    AttributeType attributeType = extractAttributeType(result);
                    return attributeType == null ? IDENTITY_CONVERTER : attributeType.getConverter();
                }
            }
            return NULL_CONVERTER;
        } else {
            AttributeType attributeType = extractAttributeType(attributeValue);
            return attributeType == null ? IDENTITY_CONVERTER : attributeType.getConverter();
        }
    }
TypeConverter getConverter ( String attributeName ) { Object attributeValue = getAttributeValue ( attributeName ) ; if ( attributeValue == null ) { return NULL_CONVERTER ; } else if ( attributeValue instanceof MultiResult ) { MultiResult multiResult = ( MultiResult ) attributeValue ; for ( Object result : multiResult . getResults ( ) ) { if ( result != null ) { AttributeType attributeType = extractAttributeType ( result ) ; return attributeType == null ? IDENTITY_CONVERTER : attributeType . getConverter ( ) ; } } return NULL_CONVERTER ; } else { AttributeType attributeType = extractAttributeType ( attributeValue ) ; return attributeType == null ? IDENTITY_CONVERTER : attributeType . getConverter ( ) ; } }
Returns a converter corresponding to the attribute with the given name.
Never {@code null}, but may return {@link TypeConverters#NULL_CONVERTER}
if the attribute value is {@code null} and therefore its type can't be
inferred. The latter may also happen for collection attributes if the
collection is empty or all its elements are {@code null}.