Package org.springframework.data.neo4j.annotation

Examples of org.springframework.data.neo4j.annotation.ResultColumn


        TypeInformation<?> fieldInfo = classInfo.getProperty(field.getName());
        return extractFromAccessibleObject(fieldInfo, columnNameFor(field));
    }

    private String columnNameFor(Field field) {
        ResultColumn column = field.getAnnotation(ResultColumn.class);
        if (column != null) return column.value();
        return field.getName();
    }
View Full Code Here


        TypeInformation<?> returnType = ClassTypeInformation.fromReturnTypeOf(method);
        return extractFromAccessibleObject(returnType, columnNameFor(method));
    }

    private String columnNameFor(Method method) {
        ResultColumn column = method.getAnnotation(ResultColumn.class);
        if (column != null) return column.value();
        String name = method.getName();
        if (name.startsWith("get")) name = name.substring(3);
        return Character.toLowerCase(name.charAt(0)) + name.substring(1);
    }
View Full Code Here

TOP

Related Classes of org.springframework.data.neo4j.annotation.ResultColumn

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.