Search in sources :

Example 66 with AnnotationMetadata

use of org.springframework.roo.classpath.details.annotations.AnnotationMetadata in project spring-roo by spring-projects.

the class DomainModelModuleMetadataProviderImpl method getMetadata.

@Override
protected ItdTypeDetailsProvidingMetadataItem getMetadata(final String metadataIdentificationString, final JavaType aspectName, final PhysicalTypeMetadata governorPhysicalTypeMetadata, final String itdFilename) {
    AnnotationMetadata annotation = governorPhysicalTypeMetadata.getMemberHoldingTypeDetails().getAnnotation(RooJavaType.ROO_DOMAIN_MODEL_MODULE);
    Map<JavaType, JavaType> mixins = new HashMap<JavaType, JavaType>();
    Set<ClassOrInterfaceTypeDetails> allJsonMixin = getTypeLocationService().findClassesOrInterfaceDetailsWithAnnotation(RooJavaType.ROO_JSON_MIXIN);
    JSONMixinAnnotationValues values;
    JavaType entity, previousMixin;
    ClassOrInterfaceTypeDetails entityDetails;
    for (ClassOrInterfaceTypeDetails mixin : allJsonMixin) {
        values = new JSONMixinAnnotationValues(mixin);
        entity = values.getEntity();
        entityDetails = getTypeLocationService().getTypeDetails(entity);
        Validate.notNull(entityDetails, "Can't get details of '%s' defined on '%s.@%s.entity'", entity.getFullyQualifiedTypeName(), mixin.getType(), RooJavaType.ROO_JSON_MIXIN.getSimpleTypeName());
        Validate.notNull(entityDetails.getAnnotation(RooJavaType.ROO_JPA_ENTITY), "Class '%s' defined on '%s.@%s.entity' has no @%s annotation. Only JPA entities can set as mixin", entity.getFullyQualifiedTypeName(), mixin.getType(), RooJavaType.ROO_JSON_MIXIN.getSimpleTypeName());
        previousMixin = mixins.put(entity, mixin.getType());
        // Check than there isn't any previous mixin definition for current entity
        Validate.isTrue(previousMixin == null, "Found two classes annotates with @%s.entity = %s: %s and %s", RooJavaType.ROO_JSON_MIXIN.getSimpleTypeName(), entity.getFullyQualifiedTypeName(), mixin.getType(), previousMixin);
        // register metadata dependency
        registerDependency(JSONMixinMetadata.createIdentifier(mixin), metadataIdentificationString);
    }
    return new DomainModelModuleMetadata(metadataIdentificationString, aspectName, governorPhysicalTypeMetadata, mixins);
}
Also used : RooJavaType(org.springframework.roo.model.RooJavaType) JavaType(org.springframework.roo.model.JavaType) HashMap(java.util.HashMap) LinkedHashMap(java.util.LinkedHashMap) ClassOrInterfaceTypeDetails(org.springframework.roo.classpath.details.ClassOrInterfaceTypeDetails) AnnotationMetadata(org.springframework.roo.classpath.details.annotations.AnnotationMetadata)

Example 67 with AnnotationMetadata

use of org.springframework.roo.classpath.details.annotations.AnnotationMetadata in project spring-roo by spring-projects.

the class JSONMixinMetadataProviderImpl method getEntityDeserializerFor.

private JavaType getEntityDeserializerFor(JavaType entity) {
    Set<ClassOrInterfaceTypeDetails> deserializers = getTypeLocationService().findClassesOrInterfaceDetailsWithAnnotation(RooJavaType.ROO_DESERIALIZER);
    for (ClassOrInterfaceTypeDetails deserializer : deserializers) {
        AnnotationMetadata annotation = deserializer.getAnnotation(RooJavaType.ROO_DESERIALIZER);
        AnnotationAttributeValue<JavaType> annotationValue = annotation.getAttribute("entity");
        if (entity.equals(annotationValue.getValue())) {
            return deserializer.getType();
        }
    }
    return null;
}
Also used : RooJavaType(org.springframework.roo.model.RooJavaType) JpaJavaType(org.springframework.roo.model.JpaJavaType) JavaType(org.springframework.roo.model.JavaType) ClassOrInterfaceTypeDetails(org.springframework.roo.classpath.details.ClassOrInterfaceTypeDetails) AnnotationMetadata(org.springframework.roo.classpath.details.annotations.AnnotationMetadata)

Example 68 with AnnotationMetadata

use of org.springframework.roo.classpath.details.annotations.AnnotationMetadata in project spring-roo by spring-projects.

the class JavaParserAnnotationMetadataBuilder method build.

@Override
public AnnotationMetadata build() {
    final AnnotationMetadataBuilder annotationMetadataBuilder = new AnnotationMetadataBuilder(annotationType, attributeValues);
    final AnnotationMetadata md = annotationMetadataBuilder.build();
    md.setCommentStructure(commentStructure);
    return md;
}
Also used : AnnotationMetadataBuilder(org.springframework.roo.classpath.details.annotations.AnnotationMetadataBuilder) AnnotationMetadata(org.springframework.roo.classpath.details.annotations.AnnotationMetadata)

Example 69 with AnnotationMetadata

use of org.springframework.roo.classpath.details.annotations.AnnotationMetadata in project spring-roo by spring-projects.

the class JavaParserAnnotationMetadataBuilder method convert.

@SuppressWarnings("unchecked")
private static MemberValuePair convert(final AnnotationAttributeValue<?> value, CompilationUnitServices compilationUnitServices) {
    if (value instanceof NestedAnnotationAttributeValue) {
        final NestedAnnotationAttributeValue castValue = (NestedAnnotationAttributeValue) value;
        AnnotationExpr annotationExpr;
        final AnnotationMetadata nestedAnnotation = castValue.getValue();
        if (castValue.getValue().getAttributeNames().size() == 0) {
            annotationExpr = new MarkerAnnotationExpr(JavaParserUtils.getNameExpr(nestedAnnotation.getAnnotationType().getSimpleTypeName()));
        } else if (castValue.getValue().getAttributeNames().size() == 1 && (castValue.getValue().getAttributeNames().get(0) == null || "value".equals(castValue.getValue().getAttributeNames().get(0).getSymbolName()))) {
            annotationExpr = new SingleMemberAnnotationExpr(JavaParserUtils.getNameExpr(nestedAnnotation.getAnnotationType().getSimpleTypeName()), convert(nestedAnnotation.getAttribute(nestedAnnotation.getAttributeNames().get(0)), compilationUnitServices).getValue());
        } else {
            final List<MemberValuePair> memberValuePairs = new ArrayList<MemberValuePair>();
            for (final JavaSymbolName attributeName : nestedAnnotation.getAttributeNames()) {
                memberValuePairs.add(convert(nestedAnnotation.getAttribute(attributeName), compilationUnitServices));
            }
            annotationExpr = new NormalAnnotationExpr(JavaParserUtils.getNameExpr(nestedAnnotation.getAnnotationType().getSimpleTypeName()), memberValuePairs);
        }
        // Add imports for nested annotation types
        JavaParserUtils.importTypeIfRequired(compilationUnitServices.getEnclosingTypeName(), compilationUnitServices.getImports(), nestedAnnotation.getAnnotationType());
        // Rely on the nested instance to know its member value pairs
        return new MemberValuePair(value.getName().getSymbolName(), annotationExpr);
    }
    if (value instanceof BooleanAttributeValue) {
        final boolean castValue = ((BooleanAttributeValue) value).getValue();
        final BooleanLiteralExpr convertedValue = new BooleanLiteralExpr(castValue);
        return new MemberValuePair(value.getName().getSymbolName(), convertedValue);
    }
    if (value instanceof CharAttributeValue) {
        final char castValue = ((CharAttributeValue) value).getValue();
        final CharLiteralExpr convertedValue = new CharLiteralExpr(new String(new char[] { castValue }));
        return new MemberValuePair(value.getName().getSymbolName(), convertedValue);
    }
    if (value instanceof LongAttributeValue) {
        final Long castValue = ((LongAttributeValue) value).getValue();
        final LongLiteralExpr convertedValue = new LongLiteralExpr(castValue.toString() + "L");
        return new MemberValuePair(value.getName().getSymbolName(), convertedValue);
    }
    if (value instanceof IntegerAttributeValue) {
        final Integer castValue = ((IntegerAttributeValue) value).getValue();
        final IntegerLiteralExpr convertedValue = new IntegerLiteralExpr(castValue.toString());
        return new MemberValuePair(value.getName().getSymbolName(), convertedValue);
    }
    if (value instanceof DoubleAttributeValue) {
        final DoubleAttributeValue doubleAttributeValue = (DoubleAttributeValue) value;
        final Double castValue = doubleAttributeValue.getValue();
        DoubleLiteralExpr convertedValue;
        if (doubleAttributeValue.isFloatingPrecisionOnly()) {
            convertedValue = new DoubleLiteralExpr(castValue.toString() + "F");
        } else {
            convertedValue = new DoubleLiteralExpr(castValue.toString() + "D");
        }
        return new MemberValuePair(value.getName().getSymbolName(), convertedValue);
    }
    if (value instanceof StringAttributeValue) {
        final String castValue = ((StringAttributeValue) value).getValue();
        final StringLiteralExpr convertedValue = new StringLiteralExpr(castValue.toString());
        return new MemberValuePair(value.getName().getSymbolName(), convertedValue);
    }
    if (value instanceof EnumAttributeValue) {
        final EnumDetails castValue = ((EnumAttributeValue) value).getValue();
        // This isn't as elegant as it could be (ie loss of type
        // parameters), but it will do for now
        final FieldAccessExpr convertedValue = new FieldAccessExpr(JavaParserUtils.getNameExpr(castValue.getType().getFullyQualifiedTypeName()), castValue.getField().getSymbolName());
        return new MemberValuePair(value.getName().getSymbolName(), convertedValue);
    }
    if (value instanceof ClassAttributeValue) {
        final JavaType castValue = ((ClassAttributeValue) value).getValue();
        // This doesn't preserve type parameters
        final NameExpr nameExpr = JavaParserUtils.importTypeIfRequired(compilationUnitServices.getEnclosingTypeName(), compilationUnitServices.getImports(), castValue);
        final ClassExpr convertedValue = new ClassExpr(JavaParserUtils.getReferenceType(nameExpr));
        return new MemberValuePair(value.getName().getSymbolName(), convertedValue);
    }
    if (value instanceof ArrayAttributeValue) {
        final ArrayAttributeValue<AnnotationAttributeValue<?>> castValue = (ArrayAttributeValue<AnnotationAttributeValue<?>>) value;
        final List<Expression> arrayElements = new ArrayList<Expression>();
        for (final AnnotationAttributeValue<?> v : castValue.getValue()) {
            final MemberValuePair converted = convert(v, compilationUnitServices);
            if (converted != null) {
                arrayElements.add(converted.getValue());
            }
        }
        return new MemberValuePair(value.getName().getSymbolName(), new ArrayInitializerExpr(arrayElements));
    }
    throw new UnsupportedOperationException("Unsupported attribute value '" + value.getName() + "' of type '" + value.getClass().getName() + "'");
}
Also used : IntegerLiteralExpr(com.github.antlrjavaparser.api.expr.IntegerLiteralExpr) ClassAttributeValue(org.springframework.roo.classpath.details.annotations.ClassAttributeValue) AnnotationExpr(com.github.antlrjavaparser.api.expr.AnnotationExpr) MarkerAnnotationExpr(com.github.antlrjavaparser.api.expr.MarkerAnnotationExpr) SingleMemberAnnotationExpr(com.github.antlrjavaparser.api.expr.SingleMemberAnnotationExpr) NormalAnnotationExpr(com.github.antlrjavaparser.api.expr.NormalAnnotationExpr) DoubleAttributeValue(org.springframework.roo.classpath.details.annotations.DoubleAttributeValue) StringLiteralExpr(com.github.antlrjavaparser.api.expr.StringLiteralExpr) NameExpr(com.github.antlrjavaparser.api.expr.NameExpr) ArrayList(java.util.ArrayList) CharAttributeValue(org.springframework.roo.classpath.details.annotations.CharAttributeValue) EnumAttributeValue(org.springframework.roo.classpath.details.annotations.EnumAttributeValue) EnumDetails(org.springframework.roo.model.EnumDetails) AnnotationMetadata(org.springframework.roo.classpath.details.annotations.AnnotationMetadata) SingleMemberAnnotationExpr(com.github.antlrjavaparser.api.expr.SingleMemberAnnotationExpr) JavaSymbolName(org.springframework.roo.model.JavaSymbolName) MemberValuePair(com.github.antlrjavaparser.api.expr.MemberValuePair) ArrayInitializerExpr(com.github.antlrjavaparser.api.expr.ArrayInitializerExpr) BooleanLiteralExpr(com.github.antlrjavaparser.api.expr.BooleanLiteralExpr) LongLiteralExpr(com.github.antlrjavaparser.api.expr.LongLiteralExpr) ArrayList(java.util.ArrayList) List(java.util.List) FieldAccessExpr(com.github.antlrjavaparser.api.expr.FieldAccessExpr) NormalAnnotationExpr(com.github.antlrjavaparser.api.expr.NormalAnnotationExpr) StringAttributeValue(org.springframework.roo.classpath.details.annotations.StringAttributeValue) NestedAnnotationAttributeValue(org.springframework.roo.classpath.details.annotations.NestedAnnotationAttributeValue) ArrayAttributeValue(org.springframework.roo.classpath.details.annotations.ArrayAttributeValue) AnnotationAttributeValue(org.springframework.roo.classpath.details.annotations.AnnotationAttributeValue) NestedAnnotationAttributeValue(org.springframework.roo.classpath.details.annotations.NestedAnnotationAttributeValue) IntegerAttributeValue(org.springframework.roo.classpath.details.annotations.IntegerAttributeValue) CharLiteralExpr(com.github.antlrjavaparser.api.expr.CharLiteralExpr) MarkerAnnotationExpr(com.github.antlrjavaparser.api.expr.MarkerAnnotationExpr) BooleanAttributeValue(org.springframework.roo.classpath.details.annotations.BooleanAttributeValue) JavaType(org.springframework.roo.model.JavaType) LongAttributeValue(org.springframework.roo.classpath.details.annotations.LongAttributeValue) DoubleLiteralExpr(com.github.antlrjavaparser.api.expr.DoubleLiteralExpr) Expression(com.github.antlrjavaparser.api.expr.Expression) ClassExpr(com.github.antlrjavaparser.api.expr.ClassExpr)

Example 70 with AnnotationMetadata

use of org.springframework.roo.classpath.details.annotations.AnnotationMetadata in project spring-roo by spring-projects.

the class JavaParserClassOrInterfaceTypeDetailsBuilder method build.

@Override
public ClassOrInterfaceTypeDetails build() {
    Validate.notEmpty(compilationUnit.getTypes(), "No types in compilation unit, so unable to continue parsing");
    ClassOrInterfaceDeclaration clazz = null;
    EnumDeclaration enumClazz = null;
    final StringBuilder sb = new StringBuilder(compilationUnit.getPackage().getName().toString());
    if (name.getEnclosingType() != null) {
        sb.append(".").append(name.getEnclosingType().getSimpleTypeName());
    }
    compilationUnitPackage = new JavaPackage(sb.toString());
    // Determine the type name, adding type parameters if possible
    final JavaType newName = JavaParserUtils.getJavaType(compilationUnitServices, typeDeclaration);
    // Revert back to the original type name (thus avoiding unnecessary
    // inferences about java.lang types; see ROO-244)
    name = new JavaType(newName.getFullyQualifiedTypeName(), newName.getEnclosingType(), newName.getArray(), newName.getDataType(), newName.getArgName(), newName.getParameters(), name.getModule());
    final ClassOrInterfaceTypeDetailsBuilder cidBuilder = new ClassOrInterfaceTypeDetailsBuilder(declaredByMetadataId);
    physicalTypeCategory = PhysicalTypeCategory.CLASS;
    if (typeDeclaration instanceof ClassOrInterfaceDeclaration) {
        clazz = (ClassOrInterfaceDeclaration) typeDeclaration;
        if (clazz.isInterface()) {
            physicalTypeCategory = PhysicalTypeCategory.INTERFACE;
        }
    } else if (typeDeclaration instanceof EnumDeclaration) {
        enumClazz = (EnumDeclaration) typeDeclaration;
        physicalTypeCategory = PhysicalTypeCategory.ENUMERATION;
    }
    Validate.notNull(physicalTypeCategory, "%s (%s for %s)", UNSUPPORTED_MESSAGE_PREFIX, typeDeclaration.getClass().getSimpleName(), name);
    cidBuilder.setName(name);
    cidBuilder.setPhysicalTypeCategory(physicalTypeCategory);
    imports = compilationUnit.getImports();
    if (imports == null) {
        imports = new ArrayList<ImportDeclaration>();
        compilationUnit.setImports(imports);
    }
    // Verify the package declaration appears to be correct
    if (compilationUnitPackage.equals(name.getPackage()) != true) {
        String warningStr = "[Warning] Compilation unit package '" + compilationUnitPackage + "' unexpected for type '" + name.getPackage() + "', it may be a nested class.";
        LOGGER.log(Level.WARNING, warningStr);
    }
    for (final ImportDeclaration importDeclaration : imports) {
        if (importDeclaration.getName() instanceof QualifiedNameExpr) {
            final String qualifier = ((QualifiedNameExpr) importDeclaration.getName()).getQualifier().toString();
            final String simpleName = importDeclaration.getName().getName();
            final String fullName = qualifier + "." + simpleName;
            // We want to calculate these...
            final JavaType type = new JavaType(fullName);
            final JavaPackage typePackage = importDeclaration.isAsterisk() ? new JavaPackage(fullName) : type.getPackage();
            // Process any comments for the import
            final CommentStructure commentStructure = new CommentStructure();
            JavaParserCommentMetadataBuilder.updateCommentsToRoo(commentStructure, importDeclaration);
            final ImportMetadataBuilder newImport = new ImportMetadataBuilder(declaredByMetadataId, 0, typePackage, type, importDeclaration.isStatic(), importDeclaration.isAsterisk());
            newImport.setCommentStructure(commentStructure);
            cidBuilder.add(newImport.build());
        }
    }
    // Convert Java Parser modifier into JDK modifier
    cidBuilder.setModifier(JavaParserUtils.getJdkModifier(typeDeclaration.getModifiers()));
    // Type parameters
    final Set<JavaSymbolName> typeParameterNames = new HashSet<JavaSymbolName>();
    for (final JavaType param : name.getParameters()) {
        final JavaSymbolName arg = param.getArgName();
        // Fortunately type names can only appear at the top-level
        if (arg != null && !JavaType.WILDCARD_NEITHER_ARG.equals(arg) && !JavaType.WILDCARD_EXTENDS_ARG.equals(arg) && !JavaType.WILDCARD_SUPER_ARG.equals(arg)) {
            typeParameterNames.add(arg);
        }
    }
    List<ClassOrInterfaceType> implementsList;
    List<AnnotationExpr> annotationsList = null;
    List<BodyDeclaration> members = null;
    if (clazz != null) {
        final List<ClassOrInterfaceType> extendsList = clazz.getExtends();
        if (extendsList != null) {
            for (final ClassOrInterfaceType candidate : extendsList) {
                final JavaType javaType = JavaParserUtils.getJavaTypeNow(compilationUnitServices, candidate, typeParameterNames);
                cidBuilder.addExtendsTypes(javaType);
            }
        }
        final List<JavaType> extendsTypes = cidBuilder.getExtendsTypes();
        // Obtain the superclass, if this is a class and one is available
        if (physicalTypeCategory == PhysicalTypeCategory.CLASS && extendsTypes.size() == 1) {
            final JavaType superclass = extendsTypes.get(0);
            final String superclassId = typeLocationService.getPhysicalTypeIdentifier(superclass);
            PhysicalTypeMetadata superPtm = null;
            if (superclassId != null) {
                superPtm = (PhysicalTypeMetadata) metadataService.get(superclassId);
            }
            if (superPtm != null && superPtm.getMemberHoldingTypeDetails() != null) {
                cidBuilder.setSuperclass(superPtm.getMemberHoldingTypeDetails());
            }
        }
        implementsList = clazz.getImplements();
        if (implementsList != null) {
            for (final ClassOrInterfaceType candidate : implementsList) {
                final JavaType javaType = JavaParserUtils.getJavaTypeNow(compilationUnitServices, candidate, typeParameterNames);
                cidBuilder.addImplementsType(javaType);
            }
        }
        annotationsList = typeDeclaration.getAnnotations();
        members = clazz.getMembers();
    }
    if (enumClazz != null) {
        final List<EnumConstantDeclaration> constants = enumClazz.getEntries();
        if (constants != null) {
            for (final EnumConstantDeclaration enumConstants : constants) {
                cidBuilder.addEnumConstant(new JavaSymbolName(enumConstants.getName()));
            }
        }
        implementsList = enumClazz.getImplements();
        annotationsList = enumClazz.getAnnotations();
        members = enumClazz.getMembers();
    }
    if (annotationsList != null) {
        for (final AnnotationExpr candidate : annotationsList) {
            final AnnotationMetadata md = JavaParserAnnotationMetadataBuilder.getInstance(candidate, compilationUnitServices).build();
            final CommentStructure commentStructure = new CommentStructure();
            JavaParserCommentMetadataBuilder.updateCommentsToRoo(commentStructure, candidate);
            md.setCommentStructure(commentStructure);
            cidBuilder.addAnnotation(md);
        }
    }
    if (members != null) {
        // type in the signature of the enclosing type
        for (final BodyDeclaration bodyDeclaration : members) {
            if (bodyDeclaration instanceof TypeDeclaration) {
                // Found a type
                innerTypes.add((TypeDeclaration) bodyDeclaration);
            }
        }
        for (final BodyDeclaration member : members) {
            if (member instanceof FieldDeclaration) {
                final FieldDeclaration castMember = (FieldDeclaration) member;
                for (final VariableDeclarator var : castMember.getVariables()) {
                    final FieldMetadata field = JavaParserFieldMetadataBuilder.getInstance(declaredByMetadataId, castMember, var, compilationUnitServices, typeParameterNames).build();
                    final CommentStructure commentStructure = new CommentStructure();
                    JavaParserCommentMetadataBuilder.updateCommentsToRoo(commentStructure, member);
                    field.setCommentStructure(commentStructure);
                    cidBuilder.addField(field);
                }
            }
            if (member instanceof MethodDeclaration) {
                final MethodDeclaration castMember = (MethodDeclaration) member;
                final MethodMetadata method = JavaParserMethodMetadataBuilder.getInstance(declaredByMetadataId, castMember, compilationUnitServices, typeParameterNames).build();
                final CommentStructure commentStructure = new CommentStructure();
                JavaParserCommentMetadataBuilder.updateCommentsToRoo(commentStructure, member);
                method.setCommentStructure(commentStructure);
                cidBuilder.addMethod(method);
            }
            if (member instanceof ConstructorDeclaration) {
                final ConstructorDeclaration castMember = (ConstructorDeclaration) member;
                final ConstructorMetadata constructor = JavaParserConstructorMetadataBuilder.getInstance(declaredByMetadataId, castMember, compilationUnitServices, typeParameterNames).build();
                final CommentStructure commentStructure = new CommentStructure();
                JavaParserCommentMetadataBuilder.updateCommentsToRoo(commentStructure, member);
                constructor.setCommentStructure(commentStructure);
                cidBuilder.addConstructor(constructor);
            }
            if (member instanceof TypeDeclaration) {
                final TypeDeclaration castMember = (TypeDeclaration) member;
                final JavaType innerType = new JavaType(castMember.getName(), name);
                final String innerTypeMetadataId = PhysicalTypeIdentifier.createIdentifier(innerType, PhysicalTypeIdentifier.getPath(declaredByMetadataId));
                final ClassOrInterfaceTypeDetails cid = new JavaParserClassOrInterfaceTypeDetailsBuilder(compilationUnit, compilationUnitServices, castMember, innerTypeMetadataId, innerType, metadataService, typeLocationService).build();
                cidBuilder.addInnerType(cid);
            }
        }
    }
    return cidBuilder.build();
}
Also used : FieldMetadata(org.springframework.roo.classpath.details.FieldMetadata) AnnotationExpr(com.github.antlrjavaparser.api.expr.AnnotationExpr) ClassOrInterfaceDeclaration(com.github.antlrjavaparser.api.body.ClassOrInterfaceDeclaration) ClassOrInterfaceType(com.github.antlrjavaparser.api.type.ClassOrInterfaceType) JavaPackage(org.springframework.roo.model.JavaPackage) CommentStructure(org.springframework.roo.classpath.details.comments.CommentStructure) AnnotationMetadata(org.springframework.roo.classpath.details.annotations.AnnotationMetadata) FieldDeclaration(com.github.antlrjavaparser.api.body.FieldDeclaration) VariableDeclarator(com.github.antlrjavaparser.api.body.VariableDeclarator) EnumConstantDeclaration(com.github.antlrjavaparser.api.body.EnumConstantDeclaration) QualifiedNameExpr(com.github.antlrjavaparser.api.expr.QualifiedNameExpr) JavaSymbolName(org.springframework.roo.model.JavaSymbolName) ConstructorDeclaration(com.github.antlrjavaparser.api.body.ConstructorDeclaration) ClassOrInterfaceTypeDetailsBuilder(org.springframework.roo.classpath.details.ClassOrInterfaceTypeDetailsBuilder) ImportMetadataBuilder(org.springframework.roo.classpath.details.ImportMetadataBuilder) HashSet(java.util.HashSet) MethodDeclaration(com.github.antlrjavaparser.api.body.MethodDeclaration) EnumDeclaration(com.github.antlrjavaparser.api.body.EnumDeclaration) JavaType(org.springframework.roo.model.JavaType) ConstructorMetadata(org.springframework.roo.classpath.details.ConstructorMetadata) PhysicalTypeMetadata(org.springframework.roo.classpath.PhysicalTypeMetadata) ImportDeclaration(com.github.antlrjavaparser.api.ImportDeclaration) BodyDeclaration(com.github.antlrjavaparser.api.body.BodyDeclaration) MethodMetadata(org.springframework.roo.classpath.details.MethodMetadata) ClassOrInterfaceTypeDetails(org.springframework.roo.classpath.details.ClassOrInterfaceTypeDetails) TypeDeclaration(com.github.antlrjavaparser.api.body.TypeDeclaration)

Aggregations

AnnotationMetadata (org.springframework.roo.classpath.details.annotations.AnnotationMetadata)109 JavaType (org.springframework.roo.model.JavaType)59 ClassOrInterfaceTypeDetails (org.springframework.roo.classpath.details.ClassOrInterfaceTypeDetails)52 JavaSymbolName (org.springframework.roo.model.JavaSymbolName)47 ArrayList (java.util.ArrayList)40 RooJavaType (org.springframework.roo.model.RooJavaType)34 AnnotationMetadataBuilder (org.springframework.roo.classpath.details.annotations.AnnotationMetadataBuilder)30 AnnotatedJavaType (org.springframework.roo.classpath.details.annotations.AnnotatedJavaType)24 FieldMetadata (org.springframework.roo.classpath.details.FieldMetadata)21 MemberDetails (org.springframework.roo.classpath.scanner.MemberDetails)20 List (java.util.List)19 ClassOrInterfaceTypeDetailsBuilder (org.springframework.roo.classpath.details.ClassOrInterfaceTypeDetailsBuilder)19 MethodMetadata (org.springframework.roo.classpath.details.MethodMetadata)18 AnnotationAttributeValue (org.springframework.roo.classpath.details.annotations.AnnotationAttributeValue)17 NestedAnnotationAttributeValue (org.springframework.roo.classpath.details.annotations.NestedAnnotationAttributeValue)16 SpringJavaType (org.springframework.roo.model.SpringJavaType)15 JdkJavaType (org.springframework.roo.model.JdkJavaType)12 JpaJavaType (org.springframework.roo.model.JpaJavaType)12 ArrayAttributeValue (org.springframework.roo.classpath.details.annotations.ArrayAttributeValue)11 LinkedHashMap (java.util.LinkedHashMap)10