Java Doc for CCounter.java in  » Parser » Rats-Parser-Generators » xtc » lang » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Parser » Rats Parser Generators » xtc.lang 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   xtc.tree.Visitor
      xtc.lang.CCounter

CCounter
public class CCounter extends Visitor (Code)
A visitor to collect statistics on a C program.
author:
   Robert Grimm
version:
   $Revision: 1.9 $


Field Summary
public  intcountAssemblyStmt
     The counter for assembly statements.
public  intcountBreakStmt
     The counter for break statements.
public  intcountCaseLabel
     The counter for case labels.
public  intcountCompoundStmt
     The counter for compound statements.
public  intcountContinueStmt
     The counter for continue statements.
public  intcountDefaultLabel
     The counter for default labels.
public  intcountDoStmt
     The counter for do-while statements.
public  intcountEmptyStmt
     The counter for empty statements.
public  intcountExpressionStmt
     The counter for expression statements.
public  intcountForStmt
     The counter for for statements.
public  intcountGotoStmt
     The counter for goto statements.
public  intcountIfElseStmt
     The counter for if-else statements.
public  intcountIfStmt
     The counter for if statements.
public  intcountLineMarker
     The counter for line markers.
public  intcountLocalLabelDecl
     The counter for local label declarations.
public  intcountNamedLabel
     The counter for named labels.
public  intcountNestedDeclaration
     The counter for nested declarations.
public  intcountNestedFunction
     The counter for nested function definitions.
public  intcountPragma
     The counter for pragmas.
public  intcountReturnStmt
     The counter for return statements.
public  intcountSwitchStmt
     The coutner for switch statements.
public  intcountTopLevelDeclaration
     The counter for top-level declarations.
public  intcountTopLevelFunction
     The counter for top-level function definitions.
public  intcountWhileStmt
     The counter for while statements.
protected  booleanisTopLevel
     The flag for top-level constructs.

Constructor Summary
public  CCounter()
     Create a new C counter.

Method Summary
public  voidclearCounters()
     Clear all counters.
public  voidprint(Printer printer)
     Print all counters.
public  voidvisit(LineMarker mark)
     Visit the specified line marker.
public  voidvisit(Pragma p)
     Visit the specified pragma.
public  voidvisitAdditiveExpression(GNode n)
     Visit the specified additive expression node.
public  voidvisitAddressExpression(GNode n)
     Visit the specified address expression node.
public  voidvisitAssemblyStatement(GNode n)
     Visit the specified assembly statement node.
public  voidvisitAssignmentExpression(GNode n)
     Visit the specified assignment expression node.
public  voidvisitBitwiseAndExpression(GNode n)
     Visit the specified bitwise and expression node.
public  voidvisitBitwiseNegationExpression(GNode n)
     Visit the specified bitwise negation expression node.
public  voidvisitBitwiseOrExpression(GNode n)
     Visit the specified bitwise or expression node.
public  voidvisitBitwiseXorExpression(GNode n)
     Visit the specified bitwise xor expression node.
public  voidvisitBreakStatement(GNode n)
     Visit the specified break statement node.
public  voidvisitCaseLabel(GNode n)
     Visit the specified case label node.
public  voidvisitCastExpression(GNode n)
     Visit the specified cast expression node.
public  voidvisitCharacterConstant(GNode n)
     Visit the specified character constant node.
public  voidvisitCommaExpression(GNode n)
     Visit the specified comma expression node.
public  voidvisitCompoundLiteral(GNode n)
     Visit the specified compound literal node.
public  voidvisitCompoundStatement(GNode n)
     Visit the specified compound statement node.
public  voidvisitConditionalExpression(GNode n)
     Visit the specified conditional expression node.
public  voidvisitContinueStatement(GNode n)
     Visit the specified continue statement node.
public  voidvisitDeclaration(GNode n)
     Visit the specified declaration node.
public  voidvisitDeclarationList(GNode n)
     Visit the specified declaration list node.
public  voidvisitDefaultLabel(GNode n)
     Visit the specified default label node.
public  voidvisitDirectComponentSelection(GNode n)
     Visit the specified direct component selection node.
public  voidvisitDoStatement(GNode n)
     Visit the specified do statement node.
public  voidvisitEmptyStatement(GNode n)
     Visit the specified empty statement node.
public  voidvisitEqualityExpression(GNode n)
     Visit the specified equality expression node.
public  voidvisitExpressionStatement(GNode n)
     Visit the specified expression statement node.
public  voidvisitFloatingConstant(GNode n)
     Visit the specified floating constant node.
public  voidvisitForStatement(GNode n)
     Visit the specified for statement node.
public  voidvisitFunctionCall(GNode n)
     Visit the specified function call node.
public  voidvisitFunctionDefinition(GNode n)
     Visit the specified function definition node.
public  voidvisitGotoStatement(GNode n)
     Visit the specified goto statement node.
public  voidvisitIfElseStatement(GNode n)
     Visit the specified if else statement node.
public  voidvisitIfStatement(GNode n)
     Visit the specified if statement node.
public  voidvisitIndirectComponentSelection(GNode n)
     Visit the specified indirect component selection node.
public  voidvisitIndirectionExpression(GNode n)
     Visit the specified indirection expression node.
public  voidvisitIntegerConstant(GNode n)
     Visit the specified integer constant node.
public  voidvisitLabeledStatement(GNode n)
     Visit the specified labeled statement node.
public  voidvisitLocalLabelDeclaration(GNode n)
     Visit the specified local label declaration node.
public  voidvisitLogicalAndExpression(GNode n)
     Visit the specified logical and expression node.
public  voidvisitLogicalNegationExpression(GNode n)
     Visit the specified logical negation expression node.
public  voidvisitLogicalOrExpression(GNode n)
     Visit the specified logical or expression node.
public  voidvisitMultiplicativeExpression(GNode n)
     Visit the specified multiplicative expression node.
public  voidvisitNamedLabel(GNode n)
     Visit the specified named label node.
public  voidvisitPostdecrementExpresson(GNode n)
     Visit the specified postdecrement expression node.
public  voidvisitPostincrementExpression(GNode n)
     Visit the specified postincrement expression node.
public  voidvisitPredecrementExpression(GNode n)
     Visit the specified predecrement expression node.
public  voidvisitPreincrementExpression(GNode n)
     Visit the specified preincrement expression node.
public  voidvisitPrimaryIdentifier(GNode n)
     Visit the specified primary identifier node.
public  voidvisitRelationalExpression(GNode n)
     Visit the specified relational expression node.
public  voidvisitReturnStatement(GNode n)
     Visit the specified return statement node.
public  voidvisitShiftExpression(GNode n)
     Visit the specified shift expression node.
public  voidvisitSizeofExpression(GNode n)
     Visit the specified sizeof expression node.
public  voidvisitStringConstant(GNode n)
     Visit the specified string constant node.
public  voidvisitSubscriptExpression(GNode n)
     Visit the specified subscript expression node.
public  voidvisitSwitchStatement(GNode n)
     Visit the specified switch statement node.
public  voidvisitTranslationUnit(GNode n)
     Visit the specified translation unit node.
public  voidvisitUnaryMinusExpression(GNode n)
     Visit the specified unary minus expression node.
public  voidvisitUnaryPlusExpression(GNode n)
     Visit the specified unary plus expression node.
public  voidvisitWhileStatement(GNode n)
     Visit the specified while statement node.

Field Detail
countAssemblyStmt
public int countAssemblyStmt(Code)
The counter for assembly statements.



countBreakStmt
public int countBreakStmt(Code)
The counter for break statements.



countCaseLabel
public int countCaseLabel(Code)
The counter for case labels.



countCompoundStmt
public int countCompoundStmt(Code)
The counter for compound statements.



countContinueStmt
public int countContinueStmt(Code)
The counter for continue statements.



countDefaultLabel
public int countDefaultLabel(Code)
The counter for default labels.



countDoStmt
public int countDoStmt(Code)
The counter for do-while statements.



countEmptyStmt
public int countEmptyStmt(Code)
The counter for empty statements.



countExpressionStmt
public int countExpressionStmt(Code)
The counter for expression statements.



countForStmt
public int countForStmt(Code)
The counter for for statements.



countGotoStmt
public int countGotoStmt(Code)
The counter for goto statements.



countIfElseStmt
public int countIfElseStmt(Code)
The counter for if-else statements.



countIfStmt
public int countIfStmt(Code)
The counter for if statements.



countLineMarker
public int countLineMarker(Code)
The counter for line markers.



countLocalLabelDecl
public int countLocalLabelDecl(Code)
The counter for local label declarations.



countNamedLabel
public int countNamedLabel(Code)
The counter for named labels.



countNestedDeclaration
public int countNestedDeclaration(Code)
The counter for nested declarations.



countNestedFunction
public int countNestedFunction(Code)
The counter for nested function definitions.



countPragma
public int countPragma(Code)
The counter for pragmas.



countReturnStmt
public int countReturnStmt(Code)
The counter for return statements.



countSwitchStmt
public int countSwitchStmt(Code)
The coutner for switch statements.



countTopLevelDeclaration
public int countTopLevelDeclaration(Code)
The counter for top-level declarations.



countTopLevelFunction
public int countTopLevelFunction(Code)
The counter for top-level function definitions.



countWhileStmt
public int countWhileStmt(Code)
The counter for while statements.



isTopLevel
protected boolean isTopLevel(Code)
The flag for top-level constructs.




Constructor Detail
CCounter
public CCounter()(Code)
Create a new C counter.




Method Detail
clearCounters
public void clearCounters()(Code)
Clear all counters.



print
public void print(Printer printer)(Code)
Print all counters.
Parameters:
  printer - The printer.



visit
public void visit(LineMarker mark)(Code)
Visit the specified line marker.



visit
public void visit(Pragma p)(Code)
Visit the specified pragma.



visitAdditiveExpression
public void visitAdditiveExpression(GNode n)(Code)
Visit the specified additive expression node.



visitAddressExpression
public void visitAddressExpression(GNode n)(Code)
Visit the specified address expression node.



visitAssemblyStatement
public void visitAssemblyStatement(GNode n)(Code)
Visit the specified assembly statement node.



visitAssignmentExpression
public void visitAssignmentExpression(GNode n)(Code)
Visit the specified assignment expression node.



visitBitwiseAndExpression
public void visitBitwiseAndExpression(GNode n)(Code)
Visit the specified bitwise and expression node.



visitBitwiseNegationExpression
public void visitBitwiseNegationExpression(GNode n)(Code)
Visit the specified bitwise negation expression node.



visitBitwiseOrExpression
public void visitBitwiseOrExpression(GNode n)(Code)
Visit the specified bitwise or expression node.



visitBitwiseXorExpression
public void visitBitwiseXorExpression(GNode n)(Code)
Visit the specified bitwise xor expression node.



visitBreakStatement
public void visitBreakStatement(GNode n)(Code)
Visit the specified break statement node.



visitCaseLabel
public void visitCaseLabel(GNode n)(Code)
Visit the specified case label node.



visitCastExpression
public void visitCastExpression(GNode n)(Code)
Visit the specified cast expression node.



visitCharacterConstant
public void visitCharacterConstant(GNode n)(Code)
Visit the specified character constant node.



visitCommaExpression
public void visitCommaExpression(GNode n)(Code)
Visit the specified comma expression node.



visitCompoundLiteral
public void visitCompoundLiteral(GNode n)(Code)
Visit the specified compound literal node.



visitCompoundStatement
public void visitCompoundStatement(GNode n)(Code)
Visit the specified compound statement node.



visitConditionalExpression
public void visitConditionalExpression(GNode n)(Code)
Visit the specified conditional expression node.



visitContinueStatement
public void visitContinueStatement(GNode n)(Code)
Visit the specified continue statement node.



visitDeclaration
public void visitDeclaration(GNode n)(Code)
Visit the specified declaration node.



visitDeclarationList
public void visitDeclarationList(GNode n)(Code)
Visit the specified declaration list node.



visitDefaultLabel
public void visitDefaultLabel(GNode n)(Code)
Visit the specified default label node.



visitDirectComponentSelection
public void visitDirectComponentSelection(GNode n)(Code)
Visit the specified direct component selection node.



visitDoStatement
public void visitDoStatement(GNode n)(Code)
Visit the specified do statement node.



visitEmptyStatement
public void visitEmptyStatement(GNode n)(Code)
Visit the specified empty statement node.



visitEqualityExpression
public void visitEqualityExpression(GNode n)(Code)
Visit the specified equality expression node.



visitExpressionStatement
public void visitExpressionStatement(GNode n)(Code)
Visit the specified expression statement node.



visitFloatingConstant
public void visitFloatingConstant(GNode n)(Code)
Visit the specified floating constant node.



visitForStatement
public void visitForStatement(GNode n)(Code)
Visit the specified for statement node.



visitFunctionCall
public void visitFunctionCall(GNode n)(Code)
Visit the specified function call node.



visitFunctionDefinition
public void visitFunctionDefinition(GNode n)(Code)
Visit the specified function definition node.



visitGotoStatement
public void visitGotoStatement(GNode n)(Code)
Visit the specified goto statement node.



visitIfElseStatement
public void visitIfElseStatement(GNode n)(Code)
Visit the specified if else statement node.



visitIfStatement
public void visitIfStatement(GNode n)(Code)
Visit the specified if statement node.



visitIndirectComponentSelection
public void visitIndirectComponentSelection(GNode n)(Code)
Visit the specified indirect component selection node.



visitIndirectionExpression
public void visitIndirectionExpression(GNode n)(Code)
Visit the specified indirection expression node.



visitIntegerConstant
public void visitIntegerConstant(GNode n)(Code)
Visit the specified integer constant node.



visitLabeledStatement
public void visitLabeledStatement(GNode n)(Code)
Visit the specified labeled statement node.



visitLocalLabelDeclaration
public void visitLocalLabelDeclaration(GNode n)(Code)
Visit the specified local label declaration node.



visitLogicalAndExpression
public void visitLogicalAndExpression(GNode n)(Code)
Visit the specified logical and expression node.



visitLogicalNegationExpression
public void visitLogicalNegationExpression(GNode n)(Code)
Visit the specified logical negation expression node.



visitLogicalOrExpression
public void visitLogicalOrExpression(GNode n)(Code)
Visit the specified logical or expression node.



visitMultiplicativeExpression
public void visitMultiplicativeExpression(GNode n)(Code)
Visit the specified multiplicative expression node.



visitNamedLabel
public void visitNamedLabel(GNode n)(Code)
Visit the specified named label node.



visitPostdecrementExpresson
public void visitPostdecrementExpresson(GNode n)(Code)
Visit the specified postdecrement expression node.



visitPostincrementExpression
public void visitPostincrementExpression(GNode n)(Code)
Visit the specified postincrement expression node.



visitPredecrementExpression
public void visitPredecrementExpression(GNode n)(Code)
Visit the specified predecrement expression node.



visitPreincrementExpression
public void visitPreincrementExpression(GNode n)(Code)
Visit the specified preincrement expression node.



visitPrimaryIdentifier
public void visitPrimaryIdentifier(GNode n)(Code)
Visit the specified primary identifier node.



visitRelationalExpression
public void visitRelationalExpression(GNode n)(Code)
Visit the specified relational expression node.



visitReturnStatement
public void visitReturnStatement(GNode n)(Code)
Visit the specified return statement node.



visitShiftExpression
public void visitShiftExpression(GNode n)(Code)
Visit the specified shift expression node.



visitSizeofExpression
public void visitSizeofExpression(GNode n)(Code)
Visit the specified sizeof expression node.



visitStringConstant
public void visitStringConstant(GNode n)(Code)
Visit the specified string constant node.



visitSubscriptExpression
public void visitSubscriptExpression(GNode n)(Code)
Visit the specified subscript expression node.



visitSwitchStatement
public void visitSwitchStatement(GNode n)(Code)
Visit the specified switch statement node.



visitTranslationUnit
public void visitTranslationUnit(GNode n)(Code)
Visit the specified translation unit node.



visitUnaryMinusExpression
public void visitUnaryMinusExpression(GNode n)(Code)
Visit the specified unary minus expression node.



visitUnaryPlusExpression
public void visitUnaryPlusExpression(GNode n)(Code)
Visit the specified unary plus expression node.



visitWhileStatement
public void visitWhileStatement(GNode n)(Code)
Visit the specified while statement node.



Methods inherited from xtc.tree.Visitor
public Object dispatch(Node node)(Code)(Java Doc)

Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.