Yate
|
SS7 ISUP implementation. More...
#include <yatesig.h>
Public Types | |
enum | { SlsAuto = -1, SlsLatest = -2, SlsCircuit = -3, SlsDefault = -4 } |
Public Member Functions | |
SS7ISUP (const NamedList ¶ms, unsigned char sio=SS7MSU::ISUP|SS7MSU::National) | |
virtual | ~SS7ISUP () |
virtual bool | initialize (const NamedList *config) |
virtual const char * | statusName () const |
virtual void | attach (SS7Layer3 *network) |
unsigned int | cicLen () const |
const String & | format () const |
bool | ignoreUnknownAddrSignals () const |
bool | setPointCode (SS7PointCode *pc, bool def) |
unsigned int | setPointCode (const NamedList ¶ms) |
SS7PointCode * | hasPointCode (const SS7PointCode &pc) |
bool | handlesRemotePC (const SS7PointCode &pc) const |
void | setLabel (SS7Label &label, const SS7PointCode &opc, const SS7PointCode &dpc, unsigned char sls=255) |
void | setDebug (bool printMsg, bool extendedDebug) |
virtual SS7MSU * | createMSU (SS7MsgISUP::Type type, unsigned char ssf, const SS7Label &label, unsigned int cic, const NamedList *params=0) const |
virtual SignallingCall * | call (SignallingMessage *msg, String &reason) |
int | transmitMessage (SS7MsgISUP *msg, const SS7Label &label, bool recvLbl, int sls=SlsDefault) |
virtual void | cleanup (const char *reason="net-out-of-order") |
virtual bool | control (NamedList ¶ms) |
bool | decodeMessage (NamedList &msg, SS7MsgISUP::Type msgType, SS7PointCode::Type pcType, const unsigned char *paramPtr, unsigned int paramLen) |
bool | encodeMessage (DataBlock &buf, SS7MsgISUP::Type msgType, SS7PointCode::Type pcType, const NamedList ¶ms, unsigned int *cic=0) |
bool | processParamCompat (const NamedList &list, unsigned int cic, bool *callReleased=0) |
Protected Member Functions | |
virtual void | destroyed () |
virtual void | timerTick (const Time &when) |
virtual void | notify (SS7Layer3 *link, int sls) |
SS7MSU * | buildMSU (SS7MsgISUP::Type type, unsigned char sio, const SS7Label &label, unsigned int cic, const NamedList *params) const |
virtual HandledMSU | receivedMSU (const SS7MSU &msu, const SS7Label &label, SS7Layer3 *network, int sls) |
virtual bool | processMSU (SS7MsgISUP::Type type, unsigned int cic, const unsigned char *paramPtr, unsigned int paramLen, const SS7Label &label, SS7Layer3 *network, int sls) |
virtual void | receivedUPU (SS7PointCode::Type type, const SS7PointCode node, SS7MSU::Services part, unsigned char cause, const SS7Label &label, int sls) |
virtual SignallingEvent * | processCircuitEvent (SignallingCircuitEvent *&event, SignallingCall *call=0) |
bool | startCircuitReset (SignallingCircuit *&cic, const String &timer) |
Protected Attributes | |
unsigned int | m_cicLen |
Friends | |
class | SS7ISUPCall |
SS7 ISUP implementation.
Implementation of SS7 ISDN User Part
anonymous enum |
Special SLS values
Constructor
params | Call controller's parameters |
sio | The default Service Information Octet |
virtual ~SS7ISUP | ( | ) | [virtual] |
Destructor
Attach a SS7 network or router to this service. Detach itself from the old one
network | Pointer to network or router to attach |
Reimplemented from SS7Layer4.
SS7MSU* buildMSU | ( | SS7MsgISUP::Type | type, |
unsigned char | sio, | ||
const SS7Label & | label, | ||
unsigned int | cic, | ||
const NamedList * | params | ||
) | const [protected] |
Create a new MSU populated with type, routing label and space for fixed part
type | Type of ISUP message |
sio | Service Information Octet |
label | Routing label for the new MSU |
cic | Circuit Identification Code |
params | Parameter list |
virtual SignallingCall* call | ( | SignallingMessage * | msg, |
String & | reason | ||
) | [virtual] |
Create an outgoing call. Send a NewCall event with the given msg parameter This method is thread safe
msg | Call parameters |
reason | Failure reason if any |
Reimplemented from SignallingCallControl.
unsigned int cicLen | ( | ) | const [inline] |
Get the length of the Circuit Identification Code for this user part
virtual void cleanup | ( | const char * | reason = "net-out-of-order" | ) | [virtual] |
Cleanup calls This method is thread safe
reason | Cleanup reason |
Reimplemented from SignallingCallControl.
Query or modify ISUP's settings or operational parameters
params | The list of parameters to query or change |
Reimplemented from SignallingComponent.
virtual SS7MSU* createMSU | ( | SS7MsgISUP::Type | type, |
unsigned char | ssf, | ||
const SS7Label & | label, | ||
unsigned int | cic, | ||
const NamedList * | params = 0 |
||
) | const [virtual] |
Create a new MSU populated with type, routing label and space for fixed part
type | Type of ISUP message |
ssf | Subservice Field |
label | Routing label for the new MSU |
cic | Circuit Identification Code |
params | Optional parameter list |
bool decodeMessage | ( | NamedList & | msg, |
SS7MsgISUP::Type | msgType, | ||
SS7PointCode::Type | pcType, | ||
const unsigned char * | paramPtr, | ||
unsigned int | paramLen | ||
) |
Decode an ISUP message buffer to a list of parameters
msg | Destination list of parameters |
msgType | The message type |
pcType | The point code type (message version) |
paramPtr | Pointer to the Parameter area (just after the message type) |
paramLen | Length of the Parameter area |
virtual void destroyed | ( | ) | [protected, virtual] |
Remove all links with other layers. Disposes the memory
Reimplemented from SS7Layer4.
bool encodeMessage | ( | DataBlock & | buf, |
SS7MsgISUP::Type | msgType, | ||
SS7PointCode::Type | pcType, | ||
const NamedList & | params, | ||
unsigned int * | cic = 0 |
||
) |
Encode an ISUP list of parameters to a buffer. The input list may contain a 'message-prefix' parameter to override this controller's prefix
buf | Destination buffer |
msgType | The message type |
pcType | The point code type (message version) |
params | Message list of parameters |
cic | Optional cic to be added before mesage |
bool handlesRemotePC | ( | const SS7PointCode & | pc | ) | const [inline] |
Check if this controller should handle a remote point code
pc | The remote point code to check |
SS7PointCode* hasPointCode | ( | const SS7PointCode & | pc | ) |
Check if the given point code is serviced by this controller
pc | The point code to check |
bool ignoreUnknownAddrSignals | ( | ) | const [inline] |
Check if the message parser of this controller should ignore unknown digits encoding
virtual bool initialize | ( | const NamedList * | config | ) | [virtual] |
Configure and initialize the call controller and user part
config | Optional configuration parameters override |
Reimplemented from SS7Layer4.
Process a notification generated by the attached network layer
link | Network or linkset that generated the notification |
sls | Signalling Link that generated the notification, negative if none |
Reimplemented from SS7L3User.
virtual SignallingEvent* processCircuitEvent | ( | SignallingCircuitEvent *& | event, |
SignallingCall * | call = 0 |
||
) | [protected, virtual] |
Process an event received from a non-reserved circuit
event | The event, will be consumed and zeroed |
call | Optional signalling call whose circuit generated the event |
Reimplemented from SignallingCallControl.
virtual bool processMSU | ( | SS7MsgISUP::Type | type, |
unsigned int | cic, | ||
const unsigned char * | paramPtr, | ||
unsigned int | paramLen, | ||
const SS7Label & | label, | ||
SS7Layer3 * | network, | ||
int | sls | ||
) | [protected, virtual] |
Process a MSU received from a Layer 3 component
type | Type of ISUP message |
cic | Circuit Identification Code |
paramPtr | Pointer to the Parameter area |
paramLen | Length of the Parameter area |
label | Routing label of the received MSU |
network | Network layer that delivered the MSU |
sls | Signalling Link the MSU was received from |
bool processParamCompat | ( | const NamedList & | list, |
unsigned int | cic, | ||
bool * | callReleased = 0 |
||
) |
Process parameter compatibility lists. Terminate an existing call if a non emtpy release call parameter(s) list is found. Send CNF if non emtpy cnf parameter(s) list is found
list | Message parameter list |
cic | The circuit code |
callReleased | Optional pointer to boolean value to be set if a call was released |
virtual HandledMSU receivedMSU | ( | const SS7MSU & | msu, |
const SS7Label & | label, | ||
SS7Layer3 * | network, | ||
int | sls | ||
) | [protected, virtual] |
Process a MSU received from a Layer 3 component
msu | Message data, starting with Service Indicator Octet |
label | Routing label of the received MSU |
network | Network layer that delivered the MSU |
sls | Signalling Link the MSU was received from |
Implements SS7L3User.
Reimplemented in SS7BICC.
virtual void receivedUPU | ( | SS7PointCode::Type | type, |
const SS7PointCode | node, | ||
SS7MSU::Services | part, | ||
unsigned char | cause, | ||
const SS7Label & | label, | ||
int | sls | ||
) | [protected, virtual] |
Notification for receiving User Part Unavailable
type | Type of Point Code |
node | Node on which the User Part is unavailable |
part | User Part (service) reported unavailable |
cause | Unavailability cause - Q.704 15.17.5 |
label | Routing label of the UPU message |
sls | Signaling link the UPU was received on |
Reimplemented from SS7L3User.
void setDebug | ( | bool | printMsg, |
bool | extendedDebug | ||
) | [inline] |
Set debug data of this call controller
printMsg | Enable/disable message printing on output |
extendedDebug | Enable/disable hex data dump if print messages is enabled |
void setLabel | ( | SS7Label & | label, |
const SS7PointCode & | opc, | ||
const SS7PointCode & | dpc, | ||
unsigned char | sls = 255 |
||
) | [inline] |
Set a routing label to be used for outgoing messages
label | Routing label to set |
opc | Originating point code |
dpc | Destination point code |
sls | Signalling Link Selection |
References SS7Label::assign().
bool setPointCode | ( | SS7PointCode * | pc, |
bool | def | ||
) |
Append a point code to the list of point codes serviced by this controller if not already there. Set default point code if requested. If the list is empty, the default point code is set to the first point code added
pc | The point code to append |
def | True if this point code is the default for outgoing calls |
unsigned int setPointCode | ( | const NamedList & | params | ) |
Append all point codes from a parameter list, use "pointcode" and "defaultpointcode" parameters
params | List of parameters to take point codes from |
bool startCircuitReset | ( | SignallingCircuit *& | cic, |
const String & | timer | ||
) | [protected] |
Initiate circuit reset. The circuit must be already reserved This method is thread safe
cic | The circuit to reset. Its referrence counter will be decreased and the pointer will be zeroed |
timer | Ellapsed timer |
virtual const char* statusName | ( | ) | const [virtual] |
Get the controller's status as text
Implements SignallingCallControl.
Send CGU if not already done. Check timeouts
when | Time to use as computing base for timeouts |
Reimplemented from SignallingComponent.
int transmitMessage | ( | SS7MsgISUP * | msg, |
const SS7Label & | label, | ||
bool | recvLbl, | ||
int | sls = SlsDefault |
||
) |
Converts an ISUP message to a Message Signal Unit and push it down the protocol stack. The given message is consumed
msg | The message to send |
label | The routing label for the message |
recvLbl | True if the given label is from a received message. If true, a new routing label will be created from the received one |
sls | Signalling Link to use for the new routing label. Ignored if recvLbl is false |
unsigned int m_cicLen [protected] |
Length of the Circuit Identification Code in octets