Examples of superInterfaceTypes()


Examples of org.eclipse.jdt.core.dom.TypeDeclaration.superInterfaceTypes()

        .newModifier(Modifier.ModifierKeyword.PUBLIC_KEYWORD);
    td.modifiers().add(modifier);
    td.setName(ast.newSimpleName("Company"));
    Name name = ast.newName("de.test.SuperCompany");
    SimpleType simpleType = ast.newSimpleType(name);
    td.superInterfaceTypes().add(simpleType);

    TypeDeclaration typeDeclaration = interfaceGenerator.generateClass(
        clazz, ast, cu);

    assertEquals(typeDeclaration.toString(), td.toString());
View Full Code Here

Examples of org.eclipse.jdt.core.dom.TypeDeclaration.superInterfaceTypes()

                if (typeDeclaration.isInterface()) {
                    // is an interface top level type
                    TypeMetadata interfaceMetadata = TypeMetadata.interfaceType(JavaMetadataUtil.getName(typeDeclaration.getName()));

                    // detect the interfaces, if any
                    for (Type superInterfaceType : (List<Type>)typeDeclaration.superInterfaceTypes()) {
                        interfaceMetadata.getInterfaceNames().add(getTypeName(superInterfaceType));
                    }

                    metadata.add(interfaceMetadata);
                } else {
View Full Code Here

Examples of org.eclipse.jdt.core.dom.TypeDeclaration.superInterfaceTypes()

                    if (superClassType != null) {
                        classMetadata.setSuperTypeName(getTypeName(superClassType));
                    }

                    // detect the interfaces, if any
                    for (Type superInterfaceType : (List<Type>)typeDeclaration.superInterfaceTypes()) {
                        classMetadata.getInterfaceNames().add(getTypeName(superInterfaceType));
                    }

                    // fields of the class top level type
                    FieldDeclaration[] fieldDeclarations = typeDeclaration.getFields();
View Full Code Here

Examples of org.eclipse.jdt.core.dom.TypeDeclaration.superInterfaceTypes()

    typeNameWriter.write(typeDeclaration, typeInfo);

    List<Type> interfaceTypeList;
    interfaceTypeList = transform(interfaceInfoList, new InterfaceInfoToType(ast));

    typeDeclaration.superInterfaceTypes().addAll(interfaceTypeList);

    return typeDeclaration;
  }

}
View Full Code Here

Examples of org.eclipse.jdt.core.dom.TypeDeclaration.superInterfaceTypes()

            throw new ShellException(sb.toString());
        }

        // reconcile the superinterfaces
        List<Type> newSuperInterfaces = getNewSuperInterfaces(typeDeclaration
                .superInterfaceTypes(), newJavaFileVisitor);
        for (Type newSuperInterface : newSuperInterfaces) {
            if (newSuperInterface.isSimpleType()) {
                SimpleType st = (SimpleType) newSuperInterface;
                Name name = ast.newName(st.getName().getFullyQualifiedName());
View Full Code Here

Examples of org.eclipse.jdt.core.dom.TypeDeclaration.superInterfaceTypes()

        for (Type newSuperInterface : newSuperInterfaces) {
            if (newSuperInterface.isSimpleType()) {
                SimpleType st = (SimpleType) newSuperInterface;
                Name name = ast.newName(st.getName().getFullyQualifiedName());
                SimpleType newSt = ast.newSimpleType(name);
                typeDeclaration.superInterfaceTypes().add(newSt);
            } else {
                // this shouldn't happen - MyBatis Generator only generates simple names
                throw new ShellException("The Java file merger only supports simple types as super interfaces");
            }
        }
View Full Code Here

Examples of org.eclipse.jdt.core.dom.TypeDeclaration.superInterfaceTypes()

            throw new ShellException(sb.toString());
        }

        // reconcile the superinterfaces
        List<Type> newSuperInterfaces = getNewSuperInterfaces(
                typeDeclaration.superInterfaceTypes(), newJavaFileVisitor);
        for (Type newSuperInterface : newSuperInterfaces) {
            typeDeclaration.superInterfaceTypes().add(
                    ASTNode.copySubtree(ast, newSuperInterface));
        }
View Full Code Here

Examples of org.eclipse.jdt.core.dom.TypeDeclaration.superInterfaceTypes()

        // reconcile the superinterfaces
        List<Type> newSuperInterfaces = getNewSuperInterfaces(
                typeDeclaration.superInterfaceTypes(), newJavaFileVisitor);
        for (Type newSuperInterface : newSuperInterfaces) {
            typeDeclaration.superInterfaceTypes().add(
                    ASTNode.copySubtree(ast, newSuperInterface));
        }

        // set the superclass
        if (newJavaFileVisitor.getSuperclass() != null) {
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.