Package com.alibaba.toolkit.util.typeconvert

Examples of com.alibaba.toolkit.util.typeconvert.ConvertFailedException


    public Object convert(Object value, ConvertChain chain) {
        Class targetType    = chain.getTargetType();
        Class componentType = targetType.getComponentType();

        if (componentType == null) {
            throw new ConvertFailedException();
        }

        if (value == null) {
            throw new ConvertFailedException().setDefaultValue(Array.newInstance(componentType, 0));
        }

        if (targetType.isInstance(value)) {
            return value;
        }
View Full Code Here

TOP

Related Classes of com.alibaba.toolkit.util.typeconvert.ConvertFailedException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.