Package org.jolokia.converter.object

Examples of org.jolokia.converter.object.StringToOpenTypeConverter.convertToObject()


   
    public static Object toOpenData(OpenType<?> otype, ClassLoader classLoader, Object value) throws OpenDataException {
        Object result;
        if (otype instanceof CompositeType && value instanceof JSONObject) {
            StringToOpenTypeConverter converter = converters.getToOpenTypeConverter();
            result = converter.convertToObject(otype, value);
        } else if (otype instanceof TabularType && value instanceof JSONObject) {
            StringToOpenTypeConverter converter = converters.getToOpenTypeConverter();
            result = converter.convertToObject(otype, value);
        } else if (otype instanceof ArrayType && value instanceof JSONArray) {
            StringToOpenTypeConverter converter = converters.getToOpenTypeConverter();
View Full Code Here


        if (otype instanceof CompositeType && value instanceof JSONObject) {
            StringToOpenTypeConverter converter = converters.getToOpenTypeConverter();
            result = converter.convertToObject(otype, value);
        } else if (otype instanceof TabularType && value instanceof JSONObject) {
            StringToOpenTypeConverter converter = converters.getToOpenTypeConverter();
            result = converter.convertToObject(otype, value);
        } else if (otype instanceof ArrayType && value instanceof JSONArray) {
            StringToOpenTypeConverter converter = converters.getToOpenTypeConverter();
            result = converter.convertToObject(otype, value);
        } else {
            result = OpenTypeGenerator.toOpenData(otype, value);
View Full Code Here

        } else if (otype instanceof TabularType && value instanceof JSONObject) {
            StringToOpenTypeConverter converter = converters.getToOpenTypeConverter();
            result = converter.convertToObject(otype, value);
        } else if (otype instanceof ArrayType && value instanceof JSONArray) {
            StringToOpenTypeConverter converter = converters.getToOpenTypeConverter();
            result = converter.convertToObject(otype, value);
        } else {
            result = OpenTypeGenerator.toOpenData(otype, value);
        }
        boolean isAssignable = result == null || otype.isValue(result);
        IllegalStateAssertion.assertTrue(isAssignable, "Value " + result + " is not a value of: " + otype);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.