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
int
countAssemblyStmt
The counter for assembly statements.
public
int
countBreakStmt
The counter for break statements.
public
int
countCaseLabel
The counter for case labels.
public
int
countCompoundStmt
The counter for compound statements.
public
int
countContinueStmt
The counter for continue statements.
public
int
countDefaultLabel
The counter for default labels.
public
int
countDoStmt
The counter for do-while statements.
public
int
countEmptyStmt
The counter for empty statements.
public
int
countExpressionStmt
The counter for expression statements.
public
int
countForStmt
The counter for for statements.
public
int
countGotoStmt
The counter for goto statements.
public
int
countIfElseStmt
The counter for if-else statements.
public
int
countIfStmt
The counter for if statements.
public
int
countLineMarker
The counter for line markers.
public
int
countLocalLabelDecl
The counter for local label declarations.
public
int
countNamedLabel
The counter for named labels.
public
int
countNestedDeclaration
The counter for nested declarations.
public
int
countNestedFunction
The counter for nested function definitions.
public
int
countPragma
The counter for pragmas.
public
int
countReturnStmt
The counter for return statements.
public
int
countSwitchStmt
The coutner for switch statements.
public
int
countTopLevelDeclaration
The counter for top-level declarations.
public
int
countTopLevelFunction
The counter for top-level function definitions.
public
int
countWhileStmt
The counter for while statements.
protected
boolean
isTopLevel
The flag for top-level constructs.
Constructor Summary
public
CCounter
()
Create a new C counter.
Method Summary
public
void
clearCounters
()
Clear all counters.
public
void
print
(
Printer
printer)
Print all counters.
public
void
visit
(
LineMarker
mark)
Visit the specified line marker.
public
void
visit
(
Pragma
p)
Visit the specified pragma.
public
void
visitAdditiveExpression
(
GNode
n)
Visit the specified additive expression node.
public
void
visitAddressExpression
(
GNode
n)
Visit the specified address expression node.
public
void
visitAssemblyStatement
(
GNode
n)
Visit the specified assembly statement node.
public
void
visitAssignmentExpression
(
GNode
n)
Visit the specified assignment expression node.
public
void
visitBitwiseAndExpression
(
GNode
n)
Visit the specified bitwise and expression node.
public
void
visitBitwiseNegationExpression
(
GNode
n)
Visit the specified bitwise negation expression node.
public
void
visitBitwiseOrExpression
(
GNode
n)
Visit the specified bitwise or expression node.
public
void
visitBitwiseXorExpression
(
GNode
n)
Visit the specified bitwise xor expression node.
public
void
visitBreakStatement
(
GNode
n)
Visit the specified break statement node.
public
void
visitCaseLabel
(
GNode
n)
Visit the specified case label node.
public
void
visitCastExpression
(
GNode
n)
Visit the specified cast expression node.
public
void
visitCharacterConstant
(
GNode
n)
Visit the specified character constant node.
public
void
visitCommaExpression
(
GNode
n)
Visit the specified comma expression node.
public
void
visitCompoundLiteral
(
GNode
n)
Visit the specified compound literal node.
public
void
visitCompoundStatement
(
GNode
n)
Visit the specified compound statement node.
public
void
visitConditionalExpression
(
GNode
n)
Visit the specified conditional expression node.
public
void
visitContinueStatement
(
GNode
n)
Visit the specified continue statement node.
public
void
visitDeclaration
(
GNode
n)
Visit the specified declaration node.
public
void
visitDeclarationList
(
GNode
n)
Visit the specified declaration list node.
public
void
visitDefaultLabel
(
GNode
n)
Visit the specified default label node.
public
void
visitDirectComponentSelection
(
GNode
n)
Visit the specified direct component selection node.
public
void
visitDoStatement
(
GNode
n)
Visit the specified do statement node.
public
void
visitEmptyStatement
(
GNode
n)
Visit the specified empty statement node.
public
void
visitEqualityExpression
(
GNode
n)
Visit the specified equality expression node.
public
void
visitExpressionStatement
(
GNode
n)
Visit the specified expression statement node.
public
void
visitFloatingConstant
(
GNode
n)
Visit the specified floating constant node.
public
void
visitForStatement
(
GNode
n)
Visit the specified for statement node.
public
void
visitFunctionCall
(
GNode
n)
Visit the specified function call node.
public
void
visitFunctionDefinition
(
GNode
n)
Visit the specified function definition node.
public
void
visitGotoStatement
(
GNode
n)
Visit the specified goto statement node.
public
void
visitIfElseStatement
(
GNode
n)
Visit the specified if else statement node.
public
void
visitIfStatement
(
GNode
n)
Visit the specified if statement node.
public
void
visitIndirectComponentSelection
(
GNode
n)
Visit the specified indirect component selection node.
public
void
visitIndirectionExpression
(
GNode
n)
Visit the specified indirection expression node.
public
void
visitIntegerConstant
(
GNode
n)
Visit the specified integer constant node.
public
void
visitLabeledStatement
(
GNode
n)
Visit the specified labeled statement node.
public
void
visitLocalLabelDeclaration
(
GNode
n)
Visit the specified local label declaration node.
public
void
visitLogicalAndExpression
(
GNode
n)
Visit the specified logical and expression node.
public
void
visitLogicalNegationExpression
(
GNode
n)
Visit the specified logical negation expression node.
public
void
visitLogicalOrExpression
(
GNode
n)
Visit the specified logical or expression node.
public
void
visitMultiplicativeExpression
(
GNode
n)
Visit the specified multiplicative expression node.
public
void
visitNamedLabel
(
GNode
n)
Visit the specified named label node.
public
void
visitPostdecrementExpresson
(
GNode
n)
Visit the specified postdecrement expression node.
public
void
visitPostincrementExpression
(
GNode
n)
Visit the specified postincrement expression node.
public
void
visitPredecrementExpression
(
GNode
n)
Visit the specified predecrement expression node.
public
void
visitPreincrementExpression
(
GNode
n)
Visit the specified preincrement expression node.
public
void
visitPrimaryIdentifier
(
GNode
n)
Visit the specified primary identifier node.
public
void
visitRelationalExpression
(
GNode
n)
Visit the specified relational expression node.
public
void
visitReturnStatement
(
GNode
n)
Visit the specified return statement node.
public
void
visitShiftExpression
(
GNode
n)
Visit the specified shift expression node.
public
void
visitSizeofExpression
(
GNode
n)
Visit the specified sizeof expression node.
public
void
visitStringConstant
(
GNode
n)
Visit the specified string constant node.
public
void
visitSubscriptExpression
(
GNode
n)
Visit the specified subscript expression node.
public
void
visitSwitchStatement
(
GNode
n)
Visit the specified switch statement node.
public
void
visitTranslationUnit
(
GNode
n)
Visit the specified translation unit node.
public
void
visitUnaryMinusExpression
(
GNode
n)
Visit the specified unary minus expression node.
public
void
visitUnaryPlusExpression
(
GNode
n)
Visit the specified unary plus expression node.
public
void
visitWhileStatement
(
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.