AnalogLineGroup Class Reference

A group of analog lines. More...

#include <yatesig.h>

Inheritance diagram for AnalogLineGroup:

SignallingCircuitGroup SignallingComponent Mutex GenObject DebugEnabler

List of all members.

Public Member Functions

 AnalogLineGroup (AnalogLine::Type type, const char *name, bool slave=false)
 AnalogLineGroup (const char *name, AnalogLineGroup *fxo)
virtual ~AnalogLineGroup ()
AnalogLine::Type type () const
ObjListlines ()
AnalogLineGroupfxo ()
bool slave ()
bool appendLine (AnalogLine *line, bool destructOnFail=true)
void removeLine (unsigned int cic)
void removeLine (AnalogLine *line)
AnalogLinefindLine (unsigned int cic)
AnalogLinefindLine (const String &address)
virtual AnalogLineEventgetEvent (const Time &when)
virtual void destruct ()

Protected Attributes

ObjList m_lines


Detailed Description

A group of analog lines.

This class is an analog line container. It may contain another group when used to monitor analog lines


Constructor & Destructor Documentation

AnalogLineGroup ( AnalogLine::Type  type,
const char *  name,
bool  slave = false 
)

Constructor. Construct an analog line group owning single lines

Parameters:
type Line type as enumeration
name Name of this component
slave True if this is an FXO group owned by an FXS one. Ignored if type is not FXO

AnalogLineGroup ( const char *  name,
AnalogLineGroup fxo 
)

Constructor. Construct an FXS analog line group owning another group of FXO analog lines. The fxo group is owned by this component and will be destructed if invalid (not FXO type)

Parameters:
name Name of this component
fxo The FXO group

virtual ~AnalogLineGroup (  )  [virtual]

Destructor


Member Function Documentation

AnalogLine::Type type (  )  const [inline]

Get this group's type

Returns:
The group's type

ObjList& lines (  )  [inline]

Get the analog lines belonging to this group

Returns:
The group's lines list

AnalogLineGroup* fxo (  )  [inline]

Get the group holding the FXO lines if present

Returns:
The group holding the FXO lines or 0

bool slave (  )  [inline]

Check if this is an FXO group owned by an FXS one

Returns:
True if this is an FXO group owned by an FXS one

bool appendLine ( AnalogLine line,
bool  destructOnFail = true 
)

Append a line to this group. Line must have the same type as this group and must be owned by this group

Parameters:
line The line to append
destructOnFail Destroy line if failed to append. Defaults to true
Returns:
True on success

void removeLine ( unsigned int  cic  ) 

Remove a line from the list and destruct it

Parameters:
cic The signalling circuit's code used by the line

void removeLine ( AnalogLine line  ) 

Remove a line from the list without destroying it

Parameters:
line The line to be removed

AnalogLine* findLine ( unsigned int  cic  ) 

Find a line by its circuit

Parameters:
cic The signalling circuit's code used by the line
Returns:
AnalogLine pointer or 0 if not found

AnalogLine* findLine ( const String address  ) 

Find a line by its address

Parameters:
address The address of the line
Returns:
AnalogLine pointer or 0 if not found

virtual AnalogLineEvent* getEvent ( const Time when  )  [virtual]

Iterate through the line list to get an event

Parameters:
when The current time
Returns:
AnalogLineEvent pointer or 0 if no events

virtual void destruct (  )  [virtual]

Remove all lines. Release object

Reimplemented from SignallingCircuitGroup.


Member Data Documentation

ObjList m_lines [protected]

The analog lines belonging to this group


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

Generated on Mon Aug 11 16:18:53 2008 for Yate by  doxygen 1.5.6