Loading...
Searching...
No Matches
TraceComponent Class Reference
OpenCSD Library : Library Component Infrastructure

Base class for all decode components in the library. More...

`#include <trc_component.h>`

Inheritance diagram for TraceComponent:
[legend]

## Public Member Functions

| TraceComponent (const std::string &name)
| TraceComponent (const std::string &name, int instIDNum)
virtual | ~TraceComponent ()
const std::string & | getComponentName () const
void | setComponentName (const std::string &name)
componentAttachPt< ITraceErrorLog > * | getErrorLogAttachPt ()
ocsd_err_t | setComponentOpMode (uint32_t op_flags)
const uint32_t | getComponentOpMode () const
const uint32_t | getSupportedOpModes () const
void | setAssocComponent (TraceComponent *assocComp)
TraceComponent * | getAssocComponent ()
void | LogDefMessage (const std::string &msg)

## Protected Member Functions

void | LogError (const ocsdError &Error)
void | LogMessage (const ocsd_err_severity_t filter_level, const std::string &msg)
const ocsd_err_severity_t | getErrorLogLevel () const
const bool | isLoggingErrorLevel (const ocsd_err_severity_t level) const
void | updateErrorLogLevel ()
void | do_attach_notify (const int num_attached)
void | Init (const std::string &name)

## Protected Attributes

uint32_t | m_op_flags
| current component operational mode flags.
uint32_t | m_supported_op_flags
| supported component operational mode flags - derived class to intialise.

## Friends

class | errLogAttachMonitor

## Detailed Description

Base class for all decode components in the library.

Provides error logging attachment point and component type and instance naming Interface for handling of component operational mode.

Definition at line 56 of file trc_component.h.

## Constructor & Destructor Documentation

## TraceComponent() [1/2]

TraceComponent::TraceComponent | ( | const std::string & | name | ) |

Here is the caller graph for this function:

## TraceComponent() [2/2]

TraceComponent::TraceComponent | ( | const std::string & | name,
|  | int | instIDNum )

## ~TraceComponent()

virtual TraceComponent::~TraceComponent | ( |  | ) |

virtual

Default Destructor

## Member Function Documentation

## do_attach_notify()

void TraceComponent::do_attach_notify | ( | const int | num_attached | ) |

protected

## getAssocComponent()

TraceComponent * TraceComponent::getAssocComponent | ( |  | ) |

inline

get associated trace component pointer

Returns
  TraceComponent *: associated component.

Definition at line 111 of file trc_component.h.

Here is the call graph for this function:
Here is the caller graph for this function:

## getComponentName()

const std::string & TraceComponent::getComponentName | ( |  | ) | const

inline

Definition at line 63 of file trc_component.h.

## getComponentOpMode()

const uint32_t TraceComponent::getComponentOpMode | ( |  | ) | const

inline

Return the current operational mode flags values

Returns
  const uint32_t : Op Mode flags.

Definition at line 86 of file trc_component.h.

Here is the caller graph for this function:

## getErrorLogAttachPt()

componentAttachPt< ITraceErrorLog > * TraceComponent::getErrorLogAttachPt | ( |  | ) |

inline

Error logger attachment point.

Definition at line 67 of file trc_component.h.

Here is the caller graph for this function:

## getErrorLogLevel()

const ocsd_err_severity_t TraceComponent::getErrorLogLevel | ( |  | ) | const

inline protected

Definition at line 126 of file trc_component.h.

## getSupportedOpModes()

const uint32_t TraceComponent::getSupportedOpModes | ( |  | ) | const

inline

Get the supported operational mode flags for this component. Base class will return nothing supported. Derived class must set the value correctly for the component.

Returns
  const uint32_t : Supported flags values.

Definition at line 95 of file trc_component.h.

## Init()

void TraceComponent::Init | ( | const std::string & | name | ) |

protected

## isLoggingErrorLevel()

const bool TraceComponent::isLoggingErrorLevel | ( | const ocsd_err_severity_t | level | ) | const

inline protected

Definition at line 127 of file trc_component.h.

## LogDefMessage()

void TraceComponent::LogDefMessage | ( | const std::string & | msg | ) |

inline

Log a message at the default severity on this component.

Definition at line 116 of file trc_component.h.

Here is the call graph for this function:

## LogError()

void TraceComponent::LogError | ( | const ocsdError & | Error | ) |

protected

Here is the caller graph for this function:

## LogMessage()

void TraceComponent::LogMessage | ( | const ocsd_err_severity_t | filter_level,
|  | const std::string & | msg )

protected

Here is the caller graph for this function:

## setAssocComponent()

void TraceComponent::setAssocComponent | ( | TraceComponent * | assocComp | ) |

inline

Set associated trace component - used by generic code to track packet processor / packet decoder pairs.

Parameters

  *assocComp | : pointer to the associated component

Definition at line 103 of file trc_component.h.

Here is the call graph for this function:
Here is the caller graph for this function:

## setComponentName()

void TraceComponent::setComponentName | ( | const std::string & | name | ) |

inline

Definition at line 64 of file trc_component.h.

## setComponentOpMode()

ocsd_err_t TraceComponent::setComponentOpMode | ( | uint32_t | op_flags | ) |

Set the operational mode for the component. This controls the way the component behaves under error conditions etc. These flags may also control output formats or data. Operation mode flags used are component specific and defined by derived classes.

Parameters

  op_flags | : Set of operation mode flags.

Returns
  ocsd_err_t : OCSD_OK if flags supported by this component, error if unsuppored

Here is the caller graph for this function:

## updateErrorLogLevel()

void TraceComponent::updateErrorLogLevel | ( |  | ) |

protected

## Friends And Related Symbol Documentation

## errLogAttachMonitor

friend class errLogAttachMonitor

friend

Definition at line 122 of file trc_component.h.

## Member Data Documentation

## m_op_flags

uint32_t TraceComponent::m_op_flags

protected

current component operational mode flags.

Definition at line 133 of file trc_component.h.

## m_supported_op_flags

uint32_t TraceComponent::m_supported_op_flags

protected

supported component operational mode flags - derived class to intialise.

Definition at line 134 of file trc_component.h.

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

- /build/libopencsd-wPklVS/libopencsd-1.5.5/decoder/include/common/trc_component.h