Package org.eclipse.cdt.core.dom.ast.cpp

Examples of org.eclipse.cdt.core.dom.ast.cpp.ICPPASTEnumerationSpecifier


  }

  private IASTDeclaration buildEnumDeclaration(final EnumDeclarationInfo enumDeclarationInfo) {
    // Ugly hack because ASTWriter doesn't support "new enums"
    final IASTName enumerationName = f.newName(("class " + enumDeclarationInfo.getName().getIdentifier()).toCharArray());
    final ICPPASTEnumerationSpecifier enumerationSpecifier = f.newEnumerationSpecifier(enumerationName);

    enumerationSpecifier.setIsScoped(true);
    for (final EnumConstantDeclarationInfo enumConstantDeclaration : enumDeclarationInfo.enumConstantDeclarations()) {
      enumerationSpecifier.addEnumerator(buildEnumConstantDeclaration(enumConstantDeclaration));
    }
    return f.newSimpleDeclaration(enumerationSpecifier);
  }
View Full Code Here

TOP

Related Classes of org.eclipse.cdt.core.dom.ast.cpp.ICPPASTEnumerationSpecifier

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.