Synalyze It!  1.1
 All Classes Functions Pages
Public Member Functions | List of all members
Results Class Reference

The Results class. More...

Public Member Functions

Result addStructureStart (Structure structure, long startPos, int iteration, String name, bool addSizeToEnclosing)
 Add start of a structure to the results. The returned result can be used to remove all results from this on using the cut method. This method is used usually when the structure is enclosed in another structure.
 
Result addStructureStartAtPosition (Structure structure, long startPos, int iteration, String name)
 Add start of a structure to the results. The returned result can be used to remove all results from this on using the cut method. This method is used usually when the structure is referenced from another position and not enclosed in another structure.
 
Result addStructureEnd (long endPos)
 Add end of a structure to the results. The returned result can be used to remove all results from this on using the cut method.
 
Result addElement (Element element, long length, int iteration, Value value)
 Add a structure element to the results. Length is specified in bytes. The returned result can be used to remove all results from this on using the cut method.
 
Result addElementBits (Element element, long length, int iteration, Value value)
 Add a structure element to the results. Length is specified in bits. The returned result can be used to remove all results from this on using the cut method.
 
 cut (Result result)
 Cut results. You usually do this when you parsed in a wrong way and need to reparse from a certain position. So save a reference to the result where you may want to restart.
 
Result getLastResult ()
 Get last result. This is the result that was added most recently.
 
Result getPrevResult (Result result)
 Get previous result. Pass here the successor of the result you want.
 
Result getResultByName (String name)
 Get result by name. The search starts at the end.
 

Detailed Description

The Results class.

A results object contains the results of the structure mapping process

Author
Andreas Pehnack
Date
2009-09-08

Member Function Documentation

Result addElement ( Element  element,
long  length,
int  iteration,
Value  value 
)

Add a structure element to the results. Length is specified in bytes. The returned result can be used to remove all results from this on using the cut method.

Author
Andreas Pehnack
Date
2009-09-08
Parameters
[in]elementThe structure element that was mapped
[in]lengthLength of the element in bytes
[in]iterationHow often was this structure element mapped consecutively? (Array of structures)
[in]valueThe value resulting of the element being mapped to the file
Returns
The added result
Result addElementBits ( Element  element,
long  length,
int  iteration,
Value  value 
)

Add a structure element to the results. Length is specified in bits. The returned result can be used to remove all results from this on using the cut method.

Author
Andreas Pehnack
Date
2012-06-07
Parameters
[in]elementThe structure element that was mapped
[in]lengthLength of the element in bits
[in]iterationHow often was this structure element mapped consecutively? (Array of structures)
[in]valueThe value resulting of the element being mapped to the file
Returns
The added result
Result addStructureEnd ( long  endPos)

Add end of a structure to the results. The returned result can be used to remove all results from this on using the cut method.

Author
Andreas Pehnack
Date
2009-09-08
Parameters
[in]endPosWhere in the file did the structure end? Padding bytes are calculated automatically
Returns
The added result
Result addStructureStart ( Structure  structure,
long  startPos,
int  iteration,
String  name,
bool  addSizeToEnclosing 
)

Add start of a structure to the results. The returned result can be used to remove all results from this on using the cut method. This method is used usually when the structure is enclosed in another structure.

Author
Andreas Pehnack
Date
2009-09-08
Parameters
[in]structureThe structure that was mapped
[in]startPosWhere in the file was the structure mapped?
[in]iterationHow often was this structure mapped consecutively? (Array of structures)
[in]nameName to show for the result
[in]addSizeToEnclosingAdd size to the enclosing structure result? Set this to true if the structure is actually contained in the enclosing structure in the result tree.
Returns
The added result
Result addStructureStartAtPosition ( Structure  structure,
long  startPos,
int  iteration,
String  name 
)

Add start of a structure to the results. The returned result can be used to remove all results from this on using the cut method. This method is used usually when the structure is referenced from another position and not enclosed in another structure.

Author
Andreas Pehnack
Date
2009-09-08
Parameters
[in]structureThe structure that was mapped
[in]startPosWhere in the file was the structure mapped?
[in]iterationHow often was this structure mapped consecutively? (Array of structures)
[in]nameName to show for the result
Returns
The added result
cut ( Result  result)

Cut results. You usually do this when you parsed in a wrong way and need to reparse from a certain position. So save a reference to the result where you may want to restart.

Author
Andreas Pehnack
Parameters
[in]resultFirst result
Date
2009-09-08
Result getLastResult ( )

Get last result. This is the result that was added most recently.

Author
Andreas Pehnack
Date
2009-09-08
Returns
The result or NULL if there is none
Result getPrevResult ( Result  result)

Get previous result. Pass here the successor of the result you want.

Author
Andreas Pehnack
Date
2009-09-08
Parameters
[in]resultThe result you want the predecessor for
Returns
The result or NULL if there is none
Result getResultByName ( String  name)

Get result by name. The search starts at the end.

Author
Andreas Pehnack
Date
2011-11-05
Parameters
[in]nameName of the result you're looking for
Returns
The result or NULL if there is none

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