Package com.hazelcast.nio.serialization

Examples of com.hazelcast.nio.serialization.FieldDefinition


    }

    private static PortableFieldExtractor getFieldExtractor(Data data, String fieldName,
            PortableContext portableContext) {

        FieldDefinition fieldDefinition = getFieldDefinition(data, fieldName, portableContext);
        int fieldType = fieldDefinition.getType().getId();
        if (fieldType < 0 || fieldType >= FIELD_EXTRACTORS.length) {
            throw new ArrayIndexOutOfBoundsException("Invalid fieldType: " + fieldType);
        }

        PortableFieldExtractor fieldExtractor = FIELD_EXTRACTORS[fieldType];
View Full Code Here


        return fieldExtractor;
    }

    private static FieldDefinition getFieldDefinition(Data data, String fieldName, PortableContext portableContext) {
        ClassDefinition classDefinition = data.getClassDefinition();
        FieldDefinition fieldDefinition = portableContext.getFieldDefinition(classDefinition, fieldName);
        if (fieldDefinition == null) {
            throw new QueryException("Unknown Portable field: " + fieldName);
        }
        return fieldDefinition;
    }
View Full Code Here

    }

    private static PortableFieldExtractor getFieldExtractor(Data data, String fieldName,
            PortableContext portableContext) {

        FieldDefinition fieldDefinition = getFieldDefinition(data, fieldName, portableContext);
        int fieldType = fieldDefinition.getType().getId();
        if (fieldType < 0 || fieldType >= FIELD_EXTRACTORS.length) {
            throw new ArrayIndexOutOfBoundsException("Invalid fieldType: " + fieldType);
        }

        PortableFieldExtractor fieldExtractor = FIELD_EXTRACTORS[fieldType];
View Full Code Here

        return fieldExtractor;
    }

    private static FieldDefinition getFieldDefinition(Data data, String fieldName, PortableContext portableContext) {
        ClassDefinition classDefinition = portableContext.lookupClassDefinition(data);
        FieldDefinition fieldDefinition = portableContext.getFieldDefinition(classDefinition, fieldName);
        if (fieldDefinition == null) {
            throw new QueryException("Unknown Portable field: " + fieldName);
        }
        return fieldDefinition;
    }
View Full Code Here

TOP

Related Classes of com.hazelcast.nio.serialization.FieldDefinition

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.