MeVisLabToolboxReference
MLCallGraphFunction Class Reference

#include <mlCallGraph.h>

List of all members.

Public Types

typedef std::map
< MLCallGraphFunction
*, MLTimeStatistics
CallGraphFunctionMap
typedef std::map< const
MLTimeProfile
*, MLTimeStatistics
TimeStatisticsMap

Public Member Functions

 MLCallGraphFunction (MLCallGraphFunctionId id, const std::string &name, const std::string &filename, int linenumber, const std::string &identifier, int type)
 ~MLCallGraphFunction ()
int type () const
 Returns the user id.
MLCallGraphFunctionId id () const
 Returns the function id.
const std::string & name () const
 Returns the name of the function.
const std::string & filename () const
 Returns the filename of the function.
int linenumber () const
 Returns the line number of the function.
const std::string & identifier () const
 Returns the identifier.
void addCallGraphNode (MLCallGraphNode *node)
 Adds a call graph node that represents a function call to this function.
void removeCallGraphNode (MLCallGraphNode *node)
 Removes a call graph node that represents a function call to this function.
const std::vector
< MLCallGraphNode * > & 
callGraphNodes () const
 Returns all call graph nodes.
std::vector< MLCallGraphNode * > & callGraphNodes ()
 Returns all call graph nodes.
void addCaller (MLCallGraphFunction *function, MLProfilingTimeType elapsed, MLProfilingTimeType consumed)
 Adds a caller function. If it is already added, then only the statistics are updated.
const CallGraphFunctionMapcallers () const
 Returns the ids of the functions that called this function.
const CallGraphFunctionMapcallees () const
 Returns the ids of the functions that are called by this function.
const MLTimeStatisticsstatisticsByCaller (MLCallGraphFunction *caller)
 Returns the statistics of the given caller.
const MLTimeStatisticsstatisticsByCallee (MLCallGraphFunction *callee)
 Returns the statistics of the given callee.
MLCallGraphFunctiongetCallee (MLCallGraphFunction *callee)
 Returns the callee object for the given function.
MLCallGraphFunctiongetCaller (MLCallGraphFunction *caller)
 Returns the caller object for the given function.
MLTimeStatisticsstatistics ()
 Returns the time statistics.
const MLTimeStatisticsstatistics () const
MLTimeStatisticsstatistics (const MLTimeProfile *timeProfile)
 @
const MLTimeStatisticsstatistics (const MLTimeProfile *timeProfile) const
bool hasStatisticsForTimeProfile (const MLTimeProfile *timeProfile) const
 @
const TimeStatisticsMapstatisticsByTimeProfile () const

Static Public Member Functions

static std::string createIdentifier (const std::string &name, const std::string &filename, int linenumber)

Friends

class MLCallGraphNode
class MLTimeProfile

Detailed Description

Definition at line 114 of file mlCallGraph.h.


Member Typedef Documentation

Definition at line 118 of file mlCallGraph.h.


Constructor & Destructor Documentation

MLCallGraphFunction::MLCallGraphFunction ( MLCallGraphFunctionId  id,
const std::string &  name,
const std::string &  filename,
int  linenumber,
const std::string &  identifier,
int  type 
)
MLCallGraphFunction::~MLCallGraphFunction ( )

Member Function Documentation

void MLCallGraphFunction::addCaller ( MLCallGraphFunction function,
MLProfilingTimeType  elapsed,
MLProfilingTimeType  consumed 
)

Adds a caller function. If it is already added, then only the statistics are updated.

void MLCallGraphFunction::addCallGraphNode ( MLCallGraphNode node)

Adds a call graph node that represents a function call to this function.

const CallGraphFunctionMap& MLCallGraphFunction::callees ( ) const [inline]

Returns the ids of the functions that are called by this function.

Definition at line 157 of file mlCallGraph.h.

const CallGraphFunctionMap& MLCallGraphFunction::callers ( ) const [inline]

Returns the ids of the functions that called this function.

Definition at line 154 of file mlCallGraph.h.

const std::vector<MLCallGraphNode*>& MLCallGraphFunction::callGraphNodes ( ) const [inline]

Returns all call graph nodes.

Definition at line 144 of file mlCallGraph.h.

std::vector<MLCallGraphNode*>& MLCallGraphFunction::callGraphNodes ( ) [inline]

Returns all call graph nodes.

Definition at line 146 of file mlCallGraph.h.

static std::string MLCallGraphFunction::createIdentifier ( const std::string &  name,
const std::string &  filename,
int  linenumber 
) [static]
const std::string& MLCallGraphFunction::filename ( ) const [inline]

Returns the filename of the function.

Definition at line 132 of file mlCallGraph.h.

MLCallGraphFunction* MLCallGraphFunction::getCallee ( MLCallGraphFunction callee)

Returns the callee object for the given function.

MLCallGraphFunction* MLCallGraphFunction::getCaller ( MLCallGraphFunction caller)

Returns the caller object for the given function.

bool MLCallGraphFunction::hasStatisticsForTimeProfile ( const MLTimeProfile timeProfile) const

@

MLCallGraphFunctionId MLCallGraphFunction::id ( ) const [inline]

Returns the function id.

Definition at line 128 of file mlCallGraph.h.

const std::string& MLCallGraphFunction::identifier ( ) const [inline]

Returns the identifier.

It identifies the function in the function pool of a time profile, i.e. it is not globally unique.

Definition at line 137 of file mlCallGraph.h.

int MLCallGraphFunction::linenumber ( ) const [inline]

Returns the line number of the function.

Definition at line 134 of file mlCallGraph.h.

const std::string& MLCallGraphFunction::name ( ) const [inline]

Returns the name of the function.

Definition at line 130 of file mlCallGraph.h.

void MLCallGraphFunction::removeCallGraphNode ( MLCallGraphNode node)

Removes a call graph node that represents a function call to this function.

MLTimeStatistics& MLCallGraphFunction::statistics ( ) [inline]

Returns the time statistics.

@

Definition at line 173 of file mlCallGraph.h.

const MLTimeStatistics& MLCallGraphFunction::statistics ( ) const [inline]

Definition at line 174 of file mlCallGraph.h.

MLTimeStatistics& MLCallGraphFunction::statistics ( const MLTimeProfile timeProfile) [inline]

@

Returns the time statistics for the given time profile. @

Definition at line 179 of file mlCallGraph.h.

const MLTimeStatistics& MLCallGraphFunction::statistics ( const MLTimeProfile timeProfile) const [inline]

Definition at line 180 of file mlCallGraph.h.

const MLTimeStatistics* MLCallGraphFunction::statisticsByCallee ( MLCallGraphFunction callee)

Returns the statistics of the given callee.

const MLTimeStatistics* MLCallGraphFunction::statisticsByCaller ( MLCallGraphFunction caller)

Returns the statistics of the given caller.

const TimeStatisticsMap& MLCallGraphFunction::statisticsByTimeProfile ( ) const [inline]

Definition at line 185 of file mlCallGraph.h.

int MLCallGraphFunction::type ( ) const [inline]

Returns the user id.

Definition at line 126 of file mlCallGraph.h.


Friends And Related Function Documentation

friend class MLCallGraphNode [friend]

Definition at line 206 of file mlCallGraph.h.

friend class MLTimeProfile [friend]

Definition at line 207 of file mlCallGraph.h.


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