edu.rice.cs.hpc.data.experiment.xml.ExperimentBuilder2 Class Reference

Builder for an XML parser for HPCViewer experiment files. More...

Inheritance diagram for edu.rice.cs.hpc.data.experiment.xml.ExperimentBuilder2:
Inheritance graph
[legend]
Collaboration diagram for edu.rice.cs.hpc.data.experiment.xml.ExperimentBuilder2:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 ExperimentBuilder2 (BaseExperiment experiment, String defaultName, IUserData< String, String > userData)
 Creating experiment with metrics.
void beginElement (String element, String[] attributes, String[] values)
void endElement (String element)
void begin ()
void content (String s)
void end ()
void setParser (Parser parser)
int getParseOK ()
int getParseErrorLineNumber ()
void error (int lineNumber)
void error ()
void Assert (boolean predicate)

Static Public Attributes

static int PARSER_OK = 0
static int PARSER_FAIL = 1
static int PARSER_OLDXML = 2

Protected Member Functions

boolean isCallingContextTree ()
void saveTokenContext (TokenXML current)
void begin_SecData (String[] attributes, String[] values)
String getAttributeByName (String name, String[] attributes, String[] values)
void endScope ()
Scope getCurrentScope ()
SourceFile getOrCreateSourceFile (String fileLine, int keyFile)

Protected Attributes

List< BaseMetricmetricList
 The parsed metric objects.
List< MetricRawmetricRawList
int numberOfPrimaryMetrics
 Number of metrics provided by the experiment file.
final int maxNumberOfMetrics = 10000
 Maximum number of metrics provided by the experiment file.
String defaultName
 The default name for the experiment, in case none is found by the parser.
ExperimentConfiguration configuration
 The parsed configuration.
Scope rootScope
Scope viewRootScope []
BaseExperiment experiment
 The experiment to own parsed objects.
Stack< ScopescopeStack
 A stack to keep track of scope nesting while parsing.
Stack< SourceFilesrcFileStack
 The current source file while parsing.
Token2.TokenXML previousToken = TokenXML.T_INVALID_ELEMENT_NAME
Token2.TokenXML elemInfoState = TokenXML.T_INVALID_ELEMENT_NAME
Parser parser
 The parser which owns this builder.
int parseOK
 Whether parsing was successful.
int parseErrorLineNumber
 The line number of the first parse error in the file.

Static Protected Attributes

static final String LINE_ATTRIBUTE = "l"
static final String NAME_ATTRIBUTE = "n"
static final String FILENAME_ATTRIBUTE = "f"
static final String VALUE_ATTRIBUTE = "v"
static final String ID_ATTRIBUTE = "i"

Private Types

enum  MetricValueDesc { Raw, Final, Derived_Incr, Derived }
enum  InfoState {
  PERIOD, UNIT, FLAG, AGGREGATE,
  NULL
}
 

Enumeration of different states of info.

More...

Private Member Functions

void end_ProfileData ()
void do_MetricFormula (String[] attributes, String[] values)
void do_METRIC (String[] attributes, String[] values)
void do_MetricRaw (String[] attributes, String[] values)
void end_MetricTable ()
void do_M (String[] attributes, String[] values)
void do_NV (String[] attributes, String[] values)
void begin_MetricRawTable ()
void end_MetricRawTable ()

Detailed Description

Builder for an XML parser for HPCViewer experiment files.

This builder will oversee the association between CCT and metrics

See also:
BaseExperimentBuilder

Definition at line 29 of file ExperimentBuilder2.java.


Member Enumeration Documentation

Enumeration of different states of info.

Author:
laksonoadhianto
Enumerator:
PERIOD 
UNIT 
FLAG 
AGGREGATE 
NULL 

Definition at line 462 of file ExperimentBuilder2.java.

Enumerator:
Raw 
Final 
Derived_Incr 
Derived 

Definition at line 215 of file ExperimentBuilder2.java.


Constructor & Destructor Documentation

edu.rice.cs.hpc.data.experiment.xml.ExperimentBuilder2.ExperimentBuilder2 ( BaseExperiment  experiment,
String  defaultName,
IUserData< String, String >  userData 
)

Member Function Documentation

void edu.rice.cs.hpc.data.experiment.xml.Builder.Assert ( boolean  predicate  )  [inherited]
void edu.rice.cs.hpc.data.experiment.xml.BaseExperimentBuilder.begin (  )  [virtual, inherited]
void edu.rice.cs.hpc.data.experiment.xml.ExperimentBuilder2.begin_MetricRawTable (  )  [private]
void edu.rice.cs.hpc.data.experiment.xml.BaseExperimentBuilder.begin_SecData ( String[]  attributes,
String[]  values 
) [protected, inherited]
void edu.rice.cs.hpc.data.experiment.xml.ExperimentBuilder2.beginElement ( String  element,
String[]  attributes,
String[]  values 
) [virtual]
void edu.rice.cs.hpc.data.experiment.xml.BaseExperimentBuilder.content ( String  s  )  [virtual, inherited]
void edu.rice.cs.hpc.data.experiment.xml.ExperimentBuilder2.do_M ( String[]  attributes,
String[]  values 
) [private]
void edu.rice.cs.hpc.data.experiment.xml.ExperimentBuilder2.do_METRIC ( String[]  attributes,
String[]  values 
) [private]
void edu.rice.cs.hpc.data.experiment.xml.ExperimentBuilder2.do_MetricFormula ( String[]  attributes,
String[]  values 
) [private]
void edu.rice.cs.hpc.data.experiment.xml.ExperimentBuilder2.do_MetricRaw ( String[]  attributes,
String[]  values 
) [private]
void edu.rice.cs.hpc.data.experiment.xml.ExperimentBuilder2.do_NV ( String[]  attributes,
String[]  values 
) [private]
void edu.rice.cs.hpc.data.experiment.xml.BaseExperimentBuilder.end (  )  [virtual, inherited]
void edu.rice.cs.hpc.data.experiment.xml.ExperimentBuilder2.end_MetricRawTable (  )  [private]
void edu.rice.cs.hpc.data.experiment.xml.ExperimentBuilder2.end_MetricTable (  )  [private]
void edu.rice.cs.hpc.data.experiment.xml.ExperimentBuilder2.end_ProfileData (  )  [private]
void edu.rice.cs.hpc.data.experiment.xml.ExperimentBuilder2.endElement ( String  element  )  [virtual]
void edu.rice.cs.hpc.data.experiment.xml.BaseExperimentBuilder.endScope (  )  [protected, inherited]
void edu.rice.cs.hpc.data.experiment.xml.Builder.error (  )  [inherited]
void edu.rice.cs.hpc.data.experiment.xml.Builder.error ( int  lineNumber  )  [inherited]
String edu.rice.cs.hpc.data.experiment.xml.BaseExperimentBuilder.getAttributeByName ( String  name,
String[]  attributes,
String[]  values 
) [protected, inherited]
Scope edu.rice.cs.hpc.data.experiment.xml.BaseExperimentBuilder.getCurrentScope (  )  [protected, inherited]
SourceFile edu.rice.cs.hpc.data.experiment.xml.BaseExperimentBuilder.getOrCreateSourceFile ( String  fileLine,
int  keyFile 
) [protected, inherited]
int edu.rice.cs.hpc.data.experiment.xml.Builder.getParseErrorLineNumber (  )  [inherited]
int edu.rice.cs.hpc.data.experiment.xml.Builder.getParseOK (  )  [inherited]
boolean edu.rice.cs.hpc.data.experiment.xml.BaseExperimentBuilder.isCallingContextTree (  )  [protected, inherited]
void edu.rice.cs.hpc.data.experiment.xml.BaseExperimentBuilder.saveTokenContext ( TokenXML  current  )  [protected, inherited]
void edu.rice.cs.hpc.data.experiment.xml.Builder.setParser ( Parser  parser  )  [inherited]

Definition at line 83 of file Builder.java.

Referenced by edu.rice.cs.hpc.data.experiment.xml.Parser.Parser().


Member Data Documentation

The default name for the experiment, in case none is found by the parser.

Definition at line 52 of file BaseExperimentBuilder.java.

Token2.TokenXML edu.rice.cs.hpc.data.experiment.xml.BaseExperimentBuilder.elemInfoState = TokenXML.T_INVALID_ELEMENT_NAME [protected, inherited]
final String edu.rice.cs.hpc.data.experiment.xml.BaseExperimentBuilder.FILENAME_ATTRIBUTE = "f" [static, protected, inherited]
final String edu.rice.cs.hpc.data.experiment.xml.BaseExperimentBuilder.ID_ATTRIBUTE = "i" [static, protected, inherited]
final String edu.rice.cs.hpc.data.experiment.xml.BaseExperimentBuilder.LINE_ATTRIBUTE = "l" [static, protected, inherited]

Maximum number of metrics provided by the experiment file.

We use the maxNumberOfMetrics value to generate short names for the self metrics

Definition at line 42 of file ExperimentBuilder2.java.

Referenced by edu.rice.cs.hpc.data.experiment.xml.ExperimentBuilder2.do_METRIC().

final String edu.rice.cs.hpc.data.experiment.xml.BaseExperimentBuilder.NAME_ATTRIBUTE = "n" [static, protected, inherited]

Number of metrics provided by the experiment file.

For each metric we will define one inclusive and one exclusive metric.

Definition at line 38 of file ExperimentBuilder2.java.

Referenced by edu.rice.cs.hpc.data.experiment.xml.ExperimentBuilder2.ExperimentBuilder2().

Whether parsing was successful.

Definition at line 46 of file Builder.java.

Referenced by edu.rice.cs.hpc.data.experiment.xml.Builder.error(), and edu.rice.cs.hpc.data.experiment.xml.Builder.getParseOK().

Definition at line 39 of file Builder.java.

Definition at line 38 of file Builder.java.

Definition at line 40 of file Builder.java.

Token2.TokenXML edu.rice.cs.hpc.data.experiment.xml.BaseExperimentBuilder.previousToken = TokenXML.T_INVALID_ELEMENT_NAME [protected, inherited]
final String edu.rice.cs.hpc.data.experiment.xml.BaseExperimentBuilder.VALUE_ATTRIBUTE = "v" [static, protected, inherited]

The documentation for this class was generated from the following file:

Generated on 5 May 2015 for HPCVIEWER by  doxygen 1.6.1