C# Class Antlr.Runtime.Debug.Profiler

Using the debug event interface, track what is happening in the parser and record statistics about the runtime.
Inheritance: Antlr.Runtime.Debug.BlankDebugEventListener
Datei anzeigen Open project: antlr/antlrcs

Public Properties

Property Type Description
DataSeparator string
NewLine string
RuntimeStatsFilename string
Version string
parser Antlr.Runtime.Debug.DebugParser

Protected Properties

Property Type Description
backtrackDepth int
currentGrammarFileName Stack
currentLine Stack
currentPos Stack
currentRuleName Stack
decisionStack Stack
decisions DoubleKeyMap
lastRealTokenTouchedInDecision IToken
uniqueRules bool>.Dictionary

Public Methods

Method Description
BeginBacktrack ( int level ) : void
ConsumeHiddenToken ( IToken token ) : void
ConsumeToken ( IToken token ) : void
EndBacktrack ( int level, bool successful ) : void
EnterDecision ( int decisionNumber, bool couldBacktrack ) : void
EnterRule ( string grammarFileName, string ruleName ) : void
ExamineRuleMemoization ( IIntStream input, int ruleIndex, int stopIndex, string ruleName ) : void
ExitDecision ( int decisionNumber ) : void
ExitRule ( string grammarFileName, string ruleName ) : void
GetDecisionStats ( ) : DoubleKeyMap
GetDecisionStatsDump ( ) : string
GetNumberOfHiddenTokens ( int i, int j ) : int
GetReport ( ) : ProfileStats
LT ( int i, IToken t ) : void
Location ( int line, int pos ) : void
Mark ( int i ) : void
Memoize ( IIntStream input, int ruleIndex, int ruleStartIndex, string ruleName ) : void
Profiler ( ) : System.Collections.Generic
Profiler ( Antlr.Runtime.Debug.DebugParser parser ) : System.Collections.Generic
RecognitionException ( RecognitionException e ) : void
Rewind ( ) : void
Rewind ( int i ) : void
SemanticPredicate ( bool result, string predicate ) : void
SetParser ( Antlr.Runtime.Debug.DebugParser parser ) : void
Terminate ( ) : void
ToNotifyString ( ) : string
ToString ( ) : string
ToString ( ProfileStats stats ) : string

Protected Methods

Method Description
CurrentDecision ( ) : DecisionEvent
LocationDescription ( ) : string
LocationDescription ( string file, string rule, int line, int pos ) : string
Trim ( int X, int n ) : int[]

Method Details

BeginBacktrack() public method

public BeginBacktrack ( int level ) : void
level int
return void

ConsumeHiddenToken() public method

public ConsumeHiddenToken ( IToken token ) : void
token IToken
return void

ConsumeToken() public method

public ConsumeToken ( IToken token ) : void
token IToken
return void

CurrentDecision() protected method

protected CurrentDecision ( ) : DecisionEvent
return DecisionEvent

EndBacktrack() public method

public EndBacktrack ( int level, bool successful ) : void
level int
successful bool
return void

EnterDecision() public method

public EnterDecision ( int decisionNumber, bool couldBacktrack ) : void
decisionNumber int
couldBacktrack bool
return void

EnterRule() public method

public EnterRule ( string grammarFileName, string ruleName ) : void
grammarFileName string
ruleName string
return void

ExamineRuleMemoization() public method

public ExamineRuleMemoization ( IIntStream input, int ruleIndex, int stopIndex, string ruleName ) : void
input IIntStream
ruleIndex int
stopIndex int
ruleName string
return void

ExitDecision() public method

public ExitDecision ( int decisionNumber ) : void
decisionNumber int
return void

ExitRule() public method

public ExitRule ( string grammarFileName, string ruleName ) : void
grammarFileName string
ruleName string
return void

GetDecisionStats() public method

public GetDecisionStats ( ) : DoubleKeyMap
return DoubleKeyMap

GetDecisionStatsDump() public method

public GetDecisionStatsDump ( ) : string
return string

GetNumberOfHiddenTokens() public method

public GetNumberOfHiddenTokens ( int i, int j ) : int
i int
j int
return int

GetReport() public method

public GetReport ( ) : ProfileStats
return ProfileStats

LT() public method

public LT ( int i, IToken t ) : void
i int
t IToken
return void

Location() public method

public Location ( int line, int pos ) : void
line int
pos int
return void

LocationDescription() protected method

protected LocationDescription ( ) : string
return string

LocationDescription() protected method

protected LocationDescription ( string file, string rule, int line, int pos ) : string
file string
rule string
line int
pos int
return string

Mark() public method

public Mark ( int i ) : void
i int
return void

Memoize() public method

public Memoize ( IIntStream input, int ruleIndex, int ruleStartIndex, string ruleName ) : void
input IIntStream
ruleIndex int
ruleStartIndex int
ruleName string
return void

Profiler() public method

public Profiler ( ) : System.Collections.Generic
return System.Collections.Generic

Profiler() public method

public Profiler ( Antlr.Runtime.Debug.DebugParser parser ) : System.Collections.Generic
parser Antlr.Runtime.Debug.DebugParser
return System.Collections.Generic

RecognitionException() public method

public RecognitionException ( RecognitionException e ) : void
e RecognitionException
return void

Rewind() public method

public Rewind ( ) : void
return void

Rewind() public method

public Rewind ( int i ) : void
i int
return void

SemanticPredicate() public method

public SemanticPredicate ( bool result, string predicate ) : void
result bool
predicate string
return void

SetParser() public method

public SetParser ( Antlr.Runtime.Debug.DebugParser parser ) : void
parser Antlr.Runtime.Debug.DebugParser
return void

Terminate() public method

public Terminate ( ) : void
return void

ToNotifyString() public method

public ToNotifyString ( ) : string
return string

ToString() public method

public ToString ( ) : string
return string

ToString() public static method

public static ToString ( ProfileStats stats ) : string
stats ProfileStats
return string

Trim() protected method

protected Trim ( int X, int n ) : int[]
X int
n int
return int[]

Property Details

DataSeparator public_oe static_oe property

public static string DataSeparator
return string

NewLine public_oe static_oe property

public static string NewLine
return string

RuntimeStatsFilename public_oe static_oe property

public static string RuntimeStatsFilename
return string

Version public_oe static_oe property

public static string Version
return string

backtrackDepth protected_oe property

protected int backtrackDepth
return int

currentGrammarFileName protected_oe property

protected Stack currentGrammarFileName
return Stack

currentLine protected_oe property

protected Stack currentLine
return Stack

currentPos protected_oe property

protected Stack currentPos
return Stack

currentRuleName protected_oe property

protected Stack currentRuleName
return Stack

decisionStack protected_oe property

protected Stack decisionStack
return Stack

decisions protected_oe property

protected DoubleKeyMap decisions
return DoubleKeyMap

lastRealTokenTouchedInDecision protected_oe property

protected IToken lastRealTokenTouchedInDecision
return IToken

parser public_oe property

public DebugParser,Antlr.Runtime.Debug parser
return Antlr.Runtime.Debug.DebugParser

uniqueRules protected_oe property

protected Dictionary uniqueRules
return bool>.Dictionary