Yate
|
SS7 TCAP implementation. More...
#include <yatesig.h>
Public Types | |
enum | TCAPType { UnknownTCAP, ITUTCAP, ANSITCAP } |
enum | TCAPUserCompActions { TC_Invoke = 1, TC_ResultLast = 2, TC_U_Error = 3, TC_U_Reject = 4, TC_R_Reject = 5, TC_L_Reject = 6, TC_InvokeNotLast = 7, TC_ResultNotLast = 8, TC_L_Cancel = 9, TC_U_Cancel = 10, TC_TimerReset = 11 } |
enum | TCAPUserTransActions { TC_Unknown = 0, TC_Unidirectional = 1, TC_Begin, TC_QueryWithPerm, TC_QueryWithoutPerm, TC_Continue, TC_ConversationWithPerm, TC_ConversationWithoutPerm, TC_End, TC_Response, TC_U_Abort, TC_P_Abort, TC_Notice } |
enum | TCAPComponentOperationClass { SuccessOrFailureReport = 1, FailureOnlyReport = 2, SuccessOnlyReport = 3, NoReport = 4 } |
enum | TCAPCounter { IncomingMsgs, OutgoingMsgs, DiscardedMsgs, NormalMsgs, AbnormalMsgs } |
Public Member Functions | |
SS7TCAP (const NamedList ¶ms) | |
virtual | ~SS7TCAP () |
virtual bool | initialize (const NamedList *config) |
virtual bool | sendData (DataBlock &data, NamedList ¶ms) |
virtual HandledMSU | receivedData (DataBlock &data, NamedList ¶ms) |
virtual HandledMSU | notifyData (DataBlock &data, NamedList ¶ms) |
bool | managementNotify (SCCP::Type type, NamedList ¶ms) |
void | attach (TCAPUser *user) |
void | detach (TCAPUser *user) |
virtual SS7TCAPError | userRequest (NamedList &requestParams) |
virtual HandledMSU | processSCCPData (SS7TCAPMessage *sccpData) |
TCAPType | tcapType () |
void | setTCAPType (TCAPType type) |
virtual void | enqueue (SS7TCAPMessage *msg) |
virtual SS7TCAPMessage * | dequeue () |
virtual const String | allocTransactionID () |
void | allocTransactionID (String &str) |
virtual SS7TCAPTransaction * | buildTransaction (SS7TCAP::TCAPUserTransActions type, const String &transactID, NamedList ¶ms, bool initLocal=true)=0 |
SS7TCAPTransaction * | getTransaction (const String &tid) |
void | removeTransaction (SS7TCAPTransaction *tr) |
virtual void | timerTick (const Time &when) |
virtual bool | sendToUser (NamedList ¶ms) |
virtual void | buildSCCPData (NamedList ¶ms, SS7TCAPTransaction *tr) |
virtual void | status (NamedList &status) |
virtual void | userStatus (NamedList &status) |
virtual HandledMSU | handleError (SS7TCAPError &error, NamedList ¶ms, DataBlock &data, SS7TCAPTransaction *tr=0) |
void | incCounter (TCAPCounter counterType) |
unsigned int | count (TCAPCounter counterType) |
Static Public Member Functions | |
static const char * | lookupTransaction (int tr) |
static int | lookupTransaction (const char *tr) |
static const char * | lookupComponent (int comp) |
static int | lookupComponent (const char *comp) |
Static Public Attributes | |
static const TokenDict | s_tcapVersion [] |
static const TokenDict | s_compPrimitives [] |
static const TokenDict | s_transPrimitives [] |
static const TokenDict | s_compOperClasses [] |
Protected Member Functions | |
virtual SS7TCAPError | decodeTransactionPart (NamedList ¶ms, DataBlock &data)=0 |
virtual void | encodeTransactionPart (NamedList ¶ms, DataBlock &data)=0 |
Protected Attributes | |
ObjList | m_users |
Mutex | m_usersMtx |
ObjList | m_inQueue |
Mutex | m_inQueueMtx |
unsigned int | m_SSN |
unsigned int | m_defaultRemoteSSN |
unsigned int | m_defaultHopCounter |
SS7PointCode | m_defaultRemotePC |
SS7PointCode::Type | m_remoteTypePC |
u_int64_t | m_trTimeout |
Mutex | m_transactionsMtx |
ObjList | m_transactions |
TCAPType | m_tcapType |
u_int32_t | m_idsPool |
unsigned int | m_recvMsgs |
unsigned int | m_sentMsgs |
unsigned int | m_discardMsgs |
unsigned int | m_normalMsgs |
unsigned int | m_abnormalMsgs |
SS7 TCAP implementation.
Implementation of SS7 Transactional Capabilities Application Part
Component Operation Classes
enum TCAPCounter |
Type of message counters
enum TCAPType |
TCAP implementation variant
enum TCAPUserCompActions |
Component handling primitives between TCAP and TCAP user (TC-user)
enum TCAPUserTransActions |
TCAP message primitives
virtual ~SS7TCAP | ( | ) | [virtual] |
Destructor
virtual const String allocTransactionID | ( | ) | [virtual] |
Get a new transaction ID
void allocTransactionID | ( | String & | str | ) |
Get a new transaction ID
str | String into which to put the id |
Attach a SS7 TCAP user
user | Pointer to the TCAP user to attach |
virtual void buildSCCPData | ( | NamedList & | params, |
SS7TCAPTransaction * | tr | ||
) | [virtual] |
virtual SS7TCAPTransaction* buildTransaction | ( | SS7TCAP::TCAPUserTransActions | type, |
const String & | transactID, | ||
NamedList & | params, | ||
bool | initLocal = true |
||
) | [pure virtual] |
Build a transaction
type | Type with which to build the transactions |
transactID | ID for the transaction |
params | Parameters for building the transaction |
initLocal | True if built by user, false if by remote end |
Implemented in SS7TCAPITU, and SS7TCAPANSI.
unsigned int count | ( | TCAPCounter | counterType | ) | [inline] |
Retrieve one of the status counters
counterType | The type of the counter to increment |
virtual SS7TCAPMessage* dequeue | ( | ) | [virtual] |
Dequeue a TCAP message when ready to process it
virtual void enqueue | ( | SS7TCAPMessage * | msg | ) | [virtual] |
Enqueue data received from SCCP as a TCAP message, kept in a processing queue
msg | A SS7TCAPMessage pointer containing all data received from SSCP |
SS7TCAPTransaction* getTransaction | ( | const String & | tid | ) |
Find the transaction with the given id
tid | Searched local id |
virtual HandledMSU handleError | ( | SS7TCAPError & | error, |
NamedList & | params, | ||
DataBlock & | data, | ||
SS7TCAPTransaction * | tr = 0 |
||
) | [virtual] |
Handle an decoding error
error | The encoutered error |
params | TCAP message parameters which where successfully decoded until the error was encoutered |
data | Data block containing the rest of the message |
tr | Transaction to which this message belongs to |
void incCounter | ( | TCAPCounter | counterType | ) | [inline] |
Increment one of the status counters
counterType | The type of the counter to increment |
virtual bool initialize | ( | const NamedList * | config | ) | [virtual] |
Configure and initialize the component and any subcomponents it may have
config | Optional configuration parameters override |
Reimplemented from SCCPUser.
static const char* lookupComponent | ( | int | comp | ) | [inline, static] |
Get the type of component in string form
comp | Type of component |
References TelEngine::lookup().
static int lookupComponent | ( | const char * | comp | ) | [inline, static] |
Get the type of component from string form
comp | Type of component |
References TelEngine::lookup().
static const char* lookupTransaction | ( | int | tr | ) | [inline, static] |
Get the type of transaction in string form
tr | Type of transaction |
References TelEngine::lookup().
static int lookupTransaction | ( | const char * | tr | ) | [inline, static] |
Get the type of transaction from string form
tr | Type of transaction in string form |
References TelEngine::lookup().
bool managementNotify | ( | SCCP::Type | type, |
NamedList & | params | ||
) | [virtual] |
virtual HandledMSU notifyData | ( | DataBlock & | data, |
NamedList & | params | ||
) | [virtual] |
Notification from SCCP that a message failed to arrive to its destination, inherited from SCCPUser
data | User data sent. |
params | SCCP parameters Note! The data may not contain the full message block previously sent (in case of SCCP segmentation), but it must always must contain the first segment |
Reimplemented from SCCPUser.
virtual HandledMSU processSCCPData | ( | SS7TCAPMessage * | sccpData | ) | [virtual] |
virtual HandledMSU receivedData | ( | DataBlock & | data, |
NamedList & | params | ||
) | [virtual] |
void removeTransaction | ( | SS7TCAPTransaction * | tr | ) |
Remove transaction
tr | The transaction to remove |
virtual bool sendToUser | ( | NamedList & | params | ) | [virtual] |
void setTCAPType | ( | TCAPType | type | ) | [inline] |
Set TCAP version
type | TCAP version |
Status of TCAP
status | NamedList to fill with status information |
Method called periodically to do processing and timeout checks
when | Time to use as computing base for events and timeouts |
Reimplemented from SignallingComponent.
virtual SS7TCAPError userRequest | ( | NamedList & | requestParams | ) | [virtual] |
A TCAP user made a request
requestParams | NamedList containing all the necessary data for the TCAP request |
virtual void userStatus | ( | NamedList & | status | ) | [virtual] |
Status of TCAP users
status | NamedList to fill with user status information |
const TokenDict s_compOperClasses[] [static] |
Dictionary for component opearation classes
const TokenDict s_compPrimitives[] [static] |
Dictionary for component primitives
const TokenDict s_tcapVersion[] [static] |
Dictionary for TCAP versions
const TokenDict s_transPrimitives[] [static] |
Dictionary for transaction primitives