|
Yate
|
A block of data that holds a Message Signal Unit. More...
#include <yatesig.h>
Public Types | |
| enum | Services { SNM = 0 , MTN = 1 , MTNS = 2 , SCCP = 3 , TUP = 4 , ISUP = 5 , DUP_C = 6 , DUP_F = 7 , MTP_T = 8 , BISUP = 9 , SISUP = 10 , AAL2 = 12 , BICC = 13 , GCP = 14 } |
| enum | Priority { Regular = 0x00 , Special = 0x10 , Circuit = 0x20 , Facility = 0x30 } |
| enum | NetIndicator { International = 0x00 , SpareInternational = 0x40 , National = 0x80 , ReservedNational = 0xc0 } |
Public Member Functions | |
| SS7MSU () | |
| SS7MSU (const SS7MSU &value) | |
| SS7MSU (const DataBlock &value) | |
| SS7MSU (void *value, unsigned int len, bool copyData=true) | |
| SS7MSU (unsigned char sio, const SS7Label label, void *value=0, unsigned int len=0) | |
| SS7MSU (unsigned char sif, unsigned char ssf, const SS7Label label, void *value=0, unsigned int len=0) | |
| virtual | ~SS7MSU () |
| SS7MSU & | operator= (const SS7MSU &value) |
| SS7MSU & | operator= (const DataBlock &value) |
| bool | valid () const |
| unsigned char * | getData (unsigned int offs, unsigned int len=1) |
| const unsigned char * | getData (unsigned int offs, unsigned int len=1) const |
| unsigned char * | getData (const SS7Label &label, unsigned int len=1) |
| const unsigned char * | getData (const SS7Label &label, unsigned int len=1) const |
| int | getSIO () const |
| int | getSIF () const |
| int | getSSF () const |
| int | getPrio () const |
| int | getNI () const |
| const char * | getServiceName () const |
| const char * | getPriorityName () const |
| const char * | getIndicatorName () const |
Public Member Functions inherited from DataBlock | |
| DataBlock (unsigned int overAlloc=0) | |
| DataBlock (const DataBlock &value) | |
| DataBlock (const DataBlock &value, unsigned int overAlloc) | |
| DataBlock (void *value, unsigned int len, bool copyData=true, unsigned int overAlloc=0) | |
| virtual | ~DataBlock () |
| virtual void * | getObject (const String &name) const |
| void * | data () const |
| unsigned char * | data (unsigned int offs, unsigned int len=1) const |
| int | at (unsigned int offs, int defvalue=-1) const |
| bool | null () const |
| unsigned int | length () const |
| unsigned int | overAlloc () const |
| void | overAlloc (unsigned int bytes) |
| void | clear (bool deleteData=true) |
| DataBlock & | assign (void *value, unsigned int len, bool copyData=true, unsigned int allocated=0) |
| void | append (void *value, unsigned int len) |
| void | append (const DataBlock &value) |
| void | append (const String &value) |
| void | insert (const DataBlock &value) |
| void | resize (unsigned int len) |
| void | truncate (unsigned int len) |
| void | cut (int len) |
| int | operator[] (signed int index) const |
| int | operator[] (unsigned int index) const |
| DataBlock & | operator= (const DataBlock &value) |
| DataBlock & | operator+= (const DataBlock &value) |
| DataBlock & | operator+= (const String &value) |
| bool | convert (const DataBlock &src, const String &sFormat, const String &dFormat, unsigned maxlen=0) |
| bool | unHexify (const char *data, unsigned int len, char sep) |
| bool | unHexify (const char *data, unsigned int len) |
| bool | unHexify (const String &data) |
| String | sqlEscape (char extraEsc) const |
Public Member Functions inherited from GenObject | |
| GenObject () | |
| virtual | ~GenObject () |
| virtual bool | alive () const |
| virtual void | destruct () |
| virtual const String & | toString () const |
| virtual const String & | traceId () const |
| NamedCounter * | getObjCounter () const |
| NamedCounter * | setObjCounter (NamedCounter *counter) |
Static Public Member Functions | |
| static unsigned char | getPriority (const char *name, unsigned char defVal=Regular) |
| static unsigned char | getNetIndicator (const char *name, unsigned char defVal=National) |
Static Public Member Functions inherited from DataBlock | |
| static const DataBlock & | empty () |
Static Public Member Functions inherited from GenObject | |
| static void * | getObject (const String &name, const GenObject *obj) |
| static bool | getObjCounting () |
| static void | setObjCounting (bool enable) |
| static NamedCounter * | getObjCounter (const String &name, bool create=true) |
| static ObjList & | getObjCounters () |
A block of data that holds a Message Signal Unit.
A raw data block with a little more understanding about MSU format
| enum NetIndicator |
Subservice types
| enum Services |
Service indicator values
|
inline |
Empty MSU constructor
Referenced by operator=(), operator=(), and SS7MSU().
Constructor from data block
| value | Raw data block to copy |
References DataBlock::DataBlock().
|
inline |
Constructor of an initialized MSU
| value | Data to assign, may be NULL to fill with zeros |
| len | Length of data, may be zero (then value is ignored) |
| copyData | True to make a copy of the data, false to use the pointer |
References DataBlock::DataBlock().
Constructor from routing label and raw data
| sio | Service Information Octet |
| label | Routing label |
| len | Length of data, may be zero (then value is ignored) |
| value | Data to assign, may be NULL to fill with zeros |
| SS7MSU | ( | unsigned char | sif, |
| unsigned char | ssf, | ||
| const SS7Label | label, | ||
| void * | value = 0, | ||
| unsigned int | len = 0 ) |
Constructor from routing label and raw data
| sif | Service Information Field |
| ssf | Subservice Field |
| label | Routing label |
| len | Length of data, may be zero (then value is ignored) |
| value | Data to assign, may be NULL to fill with zeros |
|
virtual |
Destructor
|
inline |
Get a pointer to raw user part data after a routing label
| label | Routing label of the MSU |
| len | Minimum length of data requested |
References getData(), and SS7Label::length().
|
inline |
Get a const pointer to raw user part data after a routing label
| label | Routing label of the MSU |
| len | Minimum length of data requested |
References getData(), and SS7Label::length().
|
inline |
Get a pointer to raw data
| offs | Offset in the MSU |
| len | Minimum length of data requested |
References DataBlock::data(), and DataBlock::length().
|
inline |
Get a const pointer to raw data
| offs | Offset in the MSU |
| len | Minimum length of data requested |
References DataBlock::data(), and DataBlock::length().
| const char * getIndicatorName | ( | ) | const |
Retrieve the name of the Network Indicator as decoded from the SIF
|
static |
Get the network indicator associated with a given name
| name | Network indicator name to find |
| defVal | Default value to return if not found |
|
inline |
Retrieve the Network Indicator (NI)
References DataBlock::data(), and DataBlock::null().
|
inline |
Retrieve the Priority Field
References DataBlock::data(), and DataBlock::null().
|
static |
Get the priority associated with a given name
| name | Priority name to find |
| defVal | Default value to return if not found |
| const char * getPriorityName | ( | ) | const |
Retrieve the name of the Priority as decoded from the SIF
| const char * getServiceName | ( | ) | const |
Retrieve the name of the Service as decoded from the SIF
|
inline |
Retrieve the Service Information Field
References DataBlock::data(), and DataBlock::null().
|
inline |
Retrieve the Service Information Octet
References DataBlock::data(), and DataBlock::null().
|
inline |
Retrieve the Subservice Field (SSF)
References DataBlock::data(), and DataBlock::null().
Assignment operator from data block
| value | Data block to assign |
References DataBlock::DataBlock(), DataBlock::operator=(), and SS7MSU().
Assignment operator
| value | Original MSU |
References DataBlock::operator=(), and SS7MSU().
| bool valid | ( | ) | const |
Check if the MSU length appears valid