Package reportgen.cores.ejb.annotations

Examples of reportgen.cores.ejb.annotations.DefineQueryProperty.embedded()


            String title = m.getName();
            Annotation ann = m.getAnnotation(DefineQueryProperty.class);
            boolean returnEntity =  m.getReturnType().isAnnotationPresent(Entity.class);
            if(ann != null) {
                DefineQueryProperty qp = (DefineQueryProperty) ann;
                if(!qp.embedded() && returnEntity) {
                    throw new RuntimeException("Класс " + cls.getName() + " аннотирует метод " + m.getName()
                            + " возвращающий невстроенный " + m.getReturnType().getName());
                } else if(returnEntity
                        && !m.getReturnType().isAnnotationPresent(DefineQueryEntity.class)) {
                    throw new RuntimeException("Класс " + cls.getName() + " аннотирует метод " + m.getName()
View Full Code Here


                    throw new RuntimeException("Класс " + cls.getName() + " аннотирует поле " + f.getName()
                        + " не зарегистрированного типа " +type.getName());
                }

                DefineQueryProperty qp = (DefineQueryProperty) ann;
                if(qp.embedded()) {
                    if(!isEntity) {
                        throw new RuntimeException("Класс " + cls.getName()
                                + " аннотирует поле 'не сущность' типа " + type.getName() + " как встроенное");
                    }
                    if(embedded.contains(type)) {
View Full Code Here

        for(int i=0; i<fields.length; i++) {
            Field field = (Field) fields[i];
            DefineQueryProperty gen = field.getAnnotation(DefineQueryProperty.class);
            if(gen == null) {
                continue;
            } else if(gen.embedded()) {
                embedded.add(field);
            }

            QEntityProperty qep = null;
            Class type = field.getType();
View Full Code Here

        for(int i=0; i<methods.length; i++) {
            Method method = (Method) methods[i];
            DefineQueryProperty gen = method.getAnnotation(DefineQueryProperty.class);
            if(gen == null) {
                continue;
            } else if(gen.embedded()) {
                embedded.add(method);
                continue;
            }

            Class type = method.getReturnType();
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.