/client

SMSCclientUCP

Overview

Class SMSCclientUCP
Namespace smscc.UCP
Parent TComponent
Interfaces ISMSCclientUCP

Methods

tcpConnect Connect to the SMSC on network protocol (TCP/IP) level.
tcpDisconnect Disconnect from the SMSC on network protocol (TCP/IP) level.
ucpInitializeSession Login and initialize communication session on UCP protocol level.
ucpInitializeInbound The function starts listening by the component for the connections incoming from the SMSC. This mechanism is UCP protocol specific.
ucpFinalizeInbound Procedure finalizes listening by the component for incoming connections. It should be called before calling of the tcpDisconnect method for the connection.
ucpSubmitMessage Submit message to the SMSC.
ucpSubmitMessageEx Submit message to the SMSC with extended parameter set.
ucpSubmitMessageAsync Submit message in asynchronous mode.
ucpQueryMessage Ask SMSC for the status of a formerly submitted message.
ucpDeleteMessage Remove message from the SMSC queue, providing it has not been delivered to the time.

Events

OnTcpDisconnected Event triggered on disconnection on network protocol (TCP/IP) level.
OnUcpMessageReceived Event triggered on message being received from the SMSC.
OnUcpMessageCompleted Event triggered on multipart message is reconstructed.
OnUcpSubmitResponseAsyncReceived Event triggered on receive of message submission confirmation in asynchronous submit mode.
OnUcpStatusReportReceived Event triggered on receive of status report.
OnUcpQueryResponseReceived Event triggered on receive of response to ucpQueryMessage function.
OnUcpDeleteResponseReceived Event triggered on receive of response to ucpDeleteMessage function.
OnUcpTraceProtocol Event triggered on every UCP protocol message exchanged between component and the SMSC.

Properties

Connected Returns information on connection state.
KeepAliveInterval Connection keep-alive timing.
KeepAliveOperation Protocol operation used to provide Keep Alive functionality.
ResponseTimeOut Communication timeout.
ImmediateResponse Status report confirmation mode.
ThrottleRate Message throttling limit parameter.

Methods

tcpConnect

Connect to the SMSC on network protocol (TCP/IP) level.

int tcpConnect(string RemoteHost, int RemotePort, string ExtendedParameters = "");

Parameters

RemoteHost
Either numeric or alphanumeric TCP/IP address of the SMSC ("192.168.8.16", "smsc.telecom.com" etc.)
RemotePort
Port number of the SMSC for the TCP/IP protocol connection.
ExtendedParameters
Allows passing additional parameters to the function call. For the description and syntax of parameters that can be passed this way see Extended Parameters.

Returns

If the function succeeds, the return value is zero. Negative return value means Internal Error Code. Positive value means Network Error Code.

See Also

tcpDisconnect

tcpDisconnect

Disconnect from the SMSC on network protocol (TCP/IP) level.

void tcpDisconnect();

See Also

tcpConnect

ucpInitializeSession

Login and initialize communication session on UCP protocol level.

int ucpInitializeSession(string Originator, int TON, int NPI, string Password, bool UseAuthentication, string ExtendedParameters);

Parameters

Originator
SMSC account identifier.
TON
Type Of Number.
NPI
Numbering Plan Identifier.
Password
SMSC account password.
UseAuthentication
Setting this parameter to true will cause the component to initialize not only the component's internal structures but also log in by using UCP operation type 60 (OT-60). When the value of this parameter is false then the authorization operation is not used.
ExtendedParameters
Allows passing additional parameters to the function call. For the description and syntax of parameters that can be passed this way see Extended Parameters.

Returns

If the function succeeds, the return value is zero. Negative return value means Internal Error Code. Positive value means UCP protocol Error Code.

ucpInitializeInbound

The function starts listening by the component for the connections incoming from the SMSC. This mechanism is UCP protocol specific.

int ucpInitializeInbound(string LocalHost, int LocalPort);

Parameters

LocalHost
Numeric IP address of interface that the component should listen on. In most cases should be set to the address of the local host e.g. "127.0.0.1". If empty then set to "127.0.0.1".
LocalPort
Port number on which the component should listen for incoming connections.

Returns

If the function succeeds, the return value is zero. Negative return value means Internal Error Code. Positive value means UCP protocol Error Code.

See Also

ucpFinalizeInbound

ucpFinalizeInbound

Procedure finalizes listening by the component for incoming connections. It should be called before calling of the tcpDisconnect method for the connection.

void ucpFinalizeInbound();

See Also

ucpInitializeInbound

ucpSubmitMessage

Submit message to the SMSC.

int ucpSubmitMessage(string Destination, string Originator, string Content, EncodingEnum Encoding, string UserDataHeader, SubmitOption Options, ref List< string > SystemMessages, ref List< DateTime > TimeStamps);

Parameters

Destination
Message recipient identifier. Usually this is mobile phone number in fully qualified format.
Originator
Message sender identifier. Usually this is is number of the SMSC's account (a short GSM number). This parameter can also be an alphanumeric string or general phone number where permitted.
Content
The text or content of the message to be sent. The conversion of the characters transferred by parameter to the mobile infrastructure alphabet is done according to the value passed via Encoding parameter.
Encoding
Decides on the which conversion is applied to the Content parameter to convert it to the character set supported by message. Accepted values, members of EncodingEnum type:
et7BitText Message is encoded using 7-bit GSM alphabet as in [03.38] (6.2).
et8BitHexadecimal Message contains binary data encoded in hexadecimal format. Each two hexadecimal digits encode one byte of data.
etUCS2Text Message contains Unicode character string encoded according to UCS2 coding.
etISO88591 Message encoded as Latin 1 (ISO-8859-1). Support for this encoding may depend on SMSC configuration.
etISO88595 Message encoded as Cyrllic (ISO-8859-5). Support for this encoding may depend on SMSC configuration.
etISO88598 Message encoded as Latin/Hebrew (ISO-8859-8). Support for this encoding may depend on SMSC configuration.
etWAPPushOrMMS WAP Push/MMS required encoding. Sets F5 (hex) as the Data Coding Scheme (DCS) value. Required by some SMSC providers.
UserDataHeader
User Data Header (UDH) for the message. The header must be passed as a byte string in hexadecimal format. For example: "06050415831583" is 7 bytes large header.
Options
Options that can be set for message submitted as per SubmitOptionEnum type definition. It is possible to set more than one option by using the binary OR operator on the chosen option values. Accepted values:
soRequestStatusReport Request status report for the message.
soDirectDisplay Message will be sent as a Direct Display (FlashSMS) type message.
soDeliveryTimeRelative DeliveryTime is considered relative.
soDeliveryTimeAbsolute DeliveryTime is considered absolute.
soValidityPeriodRelative Validity period will be considered relative.
soValidityPeriodAbsolute Validity period will be considered absolute.
soMessageClass0 Message class will be set to 0.
soMessageClass1 Message class will be set to 1.
soMessageClass2 Message class will be set to 2.
soMessageClass3 Message class will be set to 3.
soZeroSMS Message will be delivered as "ZERO" SMS.
SystemMessages
Message returned by the SMSC in package which responds to message submission.
TimeStamps
Time of reception of the message to transfer by the SMSC. Used to identify status report returned by the SMSC via OnUcpStatusReportReceived event. The pair TimeStamp and Destination (which uniqueness is guaranteed by the SMSC) is used to match status report with appropriate message submitted.

Returns

If the function succeeds, the return value is zero. Negative return value means Internal Error Code. Positive value means UCP protocol Error Code.

Remarks

Function returns after receiving from SMSC a response to the submission operation. If the status report (soRequestStatusReport) request option is set in the Options parameter a status report will be returned by the OnUcpStatusReportReceived event.

See Also

ucpSubmitMessageEx, ucpSubmitMessageAsync

ucpSubmitMessageEx

Submit message to the SMSC with extended parameter set.

int ucpSubmitMessageEx(string Destination, string Originator, string Content, EncodingEnum Encoding, string UserDataHeader, SubmitOption Options, DateTime DeliveryTime, DateTime ValidityPeriod, string ExtendedParameters, ref List< string > SystemMessages, ref List< DateTime > TimeStamps);

Parameters

Destination
Message recipient identifier. Usually this is mobile phone number in fully qualified format.
Originator
Message sender identifier. Usually this is is number of the SMSC's account (a short GSM number). This parameter can also be an alphanumeric string or general phone number where permitted.
Content
The text or content of the message to be sent. The conversion of the characters transferred by parameter to the mobile infrastructure alphabet is done according to the value passed via Encoding parameter.
Encoding
Decides on the which conversion is applied to the Content parameter to convert it to the character set supported by message. Accepted values, members of EncodingEnum type:
et7BitText Message is encoded using 7-bit GSM alphabet as in [03.38] (6.2).
et8BitHexadecimal Message contains binary data encoded in hexadecimal format. Each two hexadecimal digits encode one byte of data.
etUCS2Text Message contains Unicode character string encoded according to UCS2 coding.
etISO88591 Message encoded as Latin 1 (ISO-8859-1). Support for this encoding may depend on SMSC configuration.
etISO88595 Message encoded as Cyrllic (ISO-8859-5). Support for this encoding may depend on SMSC configuration.
etISO88598 Message encoded as Latin/Hebrew (ISO-8859-8). Support for this encoding may depend on SMSC configuration.
etWAPPushOrMMS WAP Push/MMS required encoding. Sets F5 (hex) as the Data Coding Scheme (DCS) value. Required by some SMSC providers.
UserDataHeader
User Data Header (UDH) for the message. The header must be passed as a byte string in hexadecimal format. For example: "06050415831583" is 7 bytes large header.
Options
Options that can be set for message submitted as per SubmitOptionEnum type definition. It is possible to set more than one option by using the binary OR operator on the chosen option values. Accepted values:
soRequestStatusReport Request status report for the message.
soDirectDisplay Message will be sent as a Direct Display (FlashSMS) type message.
soDeliveryTimeRelative DeliveryTime is considered relative.
soDeliveryTimeAbsolute DeliveryTime is considered absolute.
soValidityPeriodRelative Validity period will be considered relative.
soValidityPeriodAbsolute Validity period will be considered absolute.
soMessageClass0 Message class will be set to 0.
soMessageClass1 Message class will be set to 1.
soMessageClass2 Message class will be set to 2.
soMessageClass3 Message class will be set to 3.
soZeroSMS Message will be delivered as "ZERO" SMS.
DeliveryTime
Sets the message delivery time. Works according to the Options parameter. If Options parameter contains the flag soDeliveryTimeRelative then the delivery time is considered relative to the submission to the SMSC. If the Options parameter contains the flag soDeliveryTimeAbsolute then the delivery time is considered absolute in the machine local time zone. If both options are specified absolute time is set. When set as relative the time the maximum period is 31 days. Anything above wil be shortened to 31 days.
ValidityPeriod
Sets the message validity time. Works according to the Options parameter. If Options parameter contains the flag soValidityPeriodRelative then the message validity time is considered relative to the time when message is submitted to to the SMSC. If Options parameter contains the flag soValidityPeriodAbsolute then the message validity time is considered absolute in the machine local time zone. If both options are specified absolute time is set. When set as relative the time the maximum period is 31 days. Anything above wil be shortened to 31 days.
ExtendedParameters
Allows passing additional parameters to the function call. For the description and syntax of parameters that can be passed this way see Extended Parameters.
SystemMessages
Message returned by the SMSC in package which responds to message submission.
TimeStamps
Time of reception of the message to transfer by the SMSC. Used to identify status report returned by the SMSC via OnUcpStatusReportReceived event. The pair TimeStamp and Destination (which uniqueness is guaranteed by the SMSC) is used to match status report with appropriate message submitted.

Returns

If the function succeeds, the return value is zero. Negative return value means Internal Error Code. Positive value means UCP protocol Error Code.

Remarks

Function returns after receiving from SMSC a response to the submission operation. If the status report (soRequestStatusReport) request option is set in the Options parameter a status report will be returned by the OnUcpStatusReportReceived event.

See Also

ucpSubmitMessage, ucpSubmitMessageAsync

ucpSubmitMessageAsync

Submit message in asynchronous mode.

int ucpSubmitMessageAsync(string Destination, string Originator, string Content, EncodingEnum Encoding, string UserDataHeader, SubmitOption Options, DateTime DeliveryTime, DateTime ValidityPeriod, string ExtendedParameters, ref List< uint > TransactionNumbers);

Parameters

Destination
Message recipient identifier. Usually this is mobile phone number in fully qualified format.
Originator
Message sender identifier. Usually this is is number of the SMSC's account (a short GSM number). This parameter can also be an alphanumeric string or general phone number where permitted.
Content
The text or content of the message to be sent. The conversion of the characters transferred by parameter to the mobile infrastructure alphabet is done according to the value passed via Encoding parameter.
Encoding
Decides on the which conversion is applied to the Content parameter to convert it to the character set supported by message. Accepted values, members of EncodingEnum type:
et7BitText Message is encoded using 7-bit GSM alphabet as in [03.38] (6.2).
et8BitHexadecimal Message contains binary data encoded in hexadecimal format. Each two hexadecimal digits encode one byte of data.
etUCS2Text Message contains Unicode character string encoded according to UCS2 coding.
etISO88591 Message encoded as Latin 1 (ISO-8859-1). Support for this encoding may depend on SMSC configuration.
etISO88595 Message encoded as Cyrllic (ISO-8859-5). Support for this encoding may depend on SMSC configuration.
etISO88598 Message encoded as Latin/Hebrew (ISO-8859-8). Support for this encoding may depend on SMSC configuration.
etWAPPushOrMMS WAP Push/MMS required encoding. Sets F5 (hex) as the Data Coding Scheme (DCS) value. Required by some SMSC providers.
UserDataHeader
User Data Header (UDH) for the message. The header must be passed as a byte string in hexadecimal format. For example: "06050415831583" is 7 bytes large header.
Options
Options that can be set for message submitted as per SubmitOptionEnum type definition. It is possible to set more than one option by using the binary OR operator on the chosen option values. Accepted values:
soRequestStatusReport Request status report for the message.
soDirectDisplay Message will be sent as a Direct Display (FlashSMS) type message.
soDeliveryTimeRelative DeliveryTime is considered relative.
soDeliveryTimeAbsolute DeliveryTime is considered absolute.
soValidityPeriodRelative Validity period will be considered relative.
soValidityPeriodAbsolute Validity period will be considered absolute.
soMessageClass0 Message class will be set to 0.
soMessageClass1 Message class will be set to 1.
soMessageClass2 Message class will be set to 2.
soMessageClass3 Message class will be set to 3.
soZeroSMS Message will be delivered as "ZERO" SMS.
DeliveryTime
Sets the message delivery time. Works according to the Options parameter. If the Options parameter contains the flag soDeliveryTimeRelative then the delivery time is considered relative to the submission to the SMSC. If the Options parameter contains the flag soDeliveryTimeAbsolute then the delivery time is considered absolute in the machine local time zone. If both options are specified absolute time is set. When set as relative the time the maximum period is 31 days. Anything above wil be shortened to 31 days.
ValidityPeriod
Sets the message validity time. Works according to the Options parameter. If Options parameter contains the flag soValidityPeriodRelative then the message validity time is considered relative to the time when message is submitted to to the SMSC. If Options parameter contains the flag soValidityPeriodAbsolute then the message validity time is considered absolute in the machine local time zone. If both options are specified absolute time is set. When set as relative the time the maximum period is 31 days. Anything above wil be shortened to 31 days.
ExtendedParameters
Allows passing additional parameters to the function call. For the description and syntax of parameters that can be passed this way see Extended Parameters.
TransactionNumbers
Identifier of the transaction with the SMSC. Allows matching the submission with return code provided by the OnUcpSubmitResponseAsyncReceived event.

Returns

If the function succeeds, the return value is zero. Negative return value means Internal Error Code. Positive value means UCP protocol Error Code.

Remarks

Function returns immediately after submitting the message to the SMSC. TimeStamp required to match appropriate Stetus Report is returned via OnUcpSubmitResponseAsyncReceived event.

See Also

ucpSubmitMessage, ucpSubmitMessageEx

ucpQueryMessage

Ask SMSC for the status of a formerly submitted message.

int ucpQueryMessage(string Destination, string Originator, ref uint TransactionNumber);

Parameters

Destination
Message recipient identifier. Usually this is mobile phone number in fully qualified format.
Originator
Message sender identifier. Usually this is is number of the SMSC's account (a short GSM number). This parameter can also be an alphanumeric string or general phone number where permitted.
TransactionNumber
Identifier of the transaction with the SMSC. Allows matching the submission with return code provided by the OnUcpQueryResponseReceived event.

Returns

If the function succeeds, the return value is zero. Negative return value means Internal Error Code. Positive value means UCP protocol Error Code.

See Also

OnUcpQueryResponseReceived

ucpDeleteMessage

Remove message from the SMSC queue, providing it has not been delivered to the time.

int ucpDeleteMessage(string Destination, string Originator, DateTime TimeStamp, ref uint TransactionNumber);

Parameters

Destination
Message recipient identifier. Usually this is mobile phone number in fully qualified format.
Originator
Message sender identifier. Usually this is is number of the SMSC's account (a short GSM number). This parameter can also be an alphanumeric string or general phone number where permitted.
TimeStamp
Time of reception of the message to transfer by the SMSC returned by message submission function.
TransactionNumber
Identifier of the transaction with the SMSC. Allows matching the submission with return code provided by the OnUcpDeleteResponseReceived event.

Returns

If the function succeeds, the return value is zero. Negative return value means Internal Error Code. Positive value means UCP protocol Error Code.

See Also

OnUcpDeleteResponseReceived

Events

OnTcpDisconnected

Event triggered on disconnection on network protocol (TCP/IP) level.

public delegate void tcpDisconnectedEvent(Object Sender, tcpDisconnectedEventArgs e);

Description

The event informs about the tear down of connection between the component and the SMSC on the network layer level (TCP). Such situation may be due to disconnection by SMSC (as per the rules of protocol after the timeout of inactivity of the component, in the case when connection is not kept alive) and in the case of disconnection for other reasons concerning functioning of the network layer.

Parameters

Sender

Object sending the event.

e

Object encapsulating event parameters.

int Reason
When the result is zero the connection has been disconnected by remote party. When the result is -1 then connection has been ended by the component itself, because inproperly formatted response has been received during the attempt to communicate with the remote party. Positive value means Network Error Code.

See Also

tcpDisconnect, tcpDisconnectedEvent, tcpDisconnectedEventArgs

OnUcpMessageReceived

Event triggered on message being received from the SMSC.

public delegate void ucpMessageReceivedEvent(Object Sender, ucpMessageReceivedEventArgs e);

Description

This event will occur both in the situation of receiving messages previously stored in the SMSC's queues as well as messages received while the component is connected to the SMSC.

Parameters

Sender

Object sending the event.

e

Object encapsulating event parameters.

string Destination
Usually this is mobile phone number in canonical format.
string Originator
Usually this is is number of the SMSC's account (a short GSM number). This parameter can also be an alphanumeric string or phone number.
string Content
This can be ASCII characters string or hexadecimally encoded binary content. This value should be considered according to the value of Encoding property.
EncodingEnum Encoding
Possible values as per EncodingEnum type definition.
string UserDataHeader
If the message received contains the User Data Header (UDH), it will be returned in this field as hexadecimally encoded binary content, for example: "06050415831583". If the message does not have UDH empty string is returned.
string TimeStamp
For UCP protocol the value returned by TimeStamp may be consistent with the time of receiving the message by the SMSC only if the SMSC transmits the message to the component using UCP52 message. If the message is delivered by the SMSC using UCP01 message, the value returned by TimeStamp denotes local message reception time by set the component UCP (4.2).
string ExtendedParameters
Allows to retrieve the additional parameters from the message received. For the description and syntax of parameters that can be retreived this way see Extended Parameters.

See Also

ucpMessageReceivedEvent, ucpMessageReceivedEventArgs

OnUcpMessageCompleted

Event triggered on multipart message is reconstructed.

public delegate void ucpMessageCompletedEvent(Object Sender, ucpMessageCompletedEventArgs e);

Description

The event informs that the client has received a message which either completes a multipart message or does not need completition.

Parameters

Sender

Object sending the event.

e

Object encapsulating event parameters.

string Destination
Usually this is mobile phone number in canonical format.
string Originator
Usually this is is number of the SMSC's account (a short GSM number). This parameter can also be an alphanumeric string or phone number.
string Content
This can be ASCII characters string or hexadecimally encoded binary content. This value should be considered according to the value of Encoding property.
EncodingEnum Encoding
Possible values as per EncodingEnum type definition.
string UserDataHeader
If the message Completed contains the User Data Header (UDH), it will be returned in this field as hexadecimally encoded binary content, for example: "06050415831583". If the message does not have UDH empty string is returned.
string TimeStamp
For UCP protocol the value returned by TimeStamp may be consistent with the time of receiving the message by the SMSC only if the SMSC transmits the message to the component using UCP52 message. If the message is delivered by the SMSC using UCP01 message, the value returned by TimeStamp denotes local message reception time by set the component UCP (4.2).
string ExtendedParameters
Allows to retrieve the additional parameters from the message Completed. For the description and syntax of parameters that can be retreived this way see Extended Parameters.

OnUcpSubmitResponseAsyncReceived

Event triggered on receive of message submission confirmation in asynchronous submit mode.

public delegate void ucpSubmitResponseAsyncReceivedEvent(Object Sender, ucpSubmitResponseAsyncReceivedEventArgs e);

Description

The event informs about the response to the message, submitted via ucpSubmitMessageAsync function. It should be implemented only if ucpSubmitMessageAsync is used.

Parameters

Sender

Object sending the event.

e

Object encapsulating event parameters.

uint TransactionNumber
Allows matching the submission with message submitted using the [ucpSubmitMessageAsync](SMSCclientNET::ucpSubmitMessageAsync) function.
int Status
Value has the same meaning as the result value returned from the ucpSubmitMessage and ucpSubmitMessageEx functions. See UCP error codes chapter Delivery Status section for list of possible values.
string SystemMessage
In some configurations contains additional information or commentary on error codes returned.
string TimeStamp
Date and time according to the SMSC configuration standard.

See Also

ucpSubmitMessageAsync, ucpSubmitResponseAsyncReceivedEvent, ucpSubmitResponseAsyncReceivedEventArgs

OnUcpStatusReportReceived

Event triggered on receive of status report.

public delegate void ucpStatusReportReceivedEvent(Object Sender, ucpStatusReportReceivedEventArgs e);

Description

The event informs about receive of a message delivering status report from the SMSC.

Parameters

Sender

Object sending the event.

e

Object encapsulating event parameters.

DateTime DeliveryTimeStamp
Assigned on message submission to the SMSC.
string Destination
Usually this is mobile phone number in canonical format.
string Originator
Usually this is is number of the SMSC's account (a short GSM number). This parameter can also be an alphanumeric string or phone number.
int DeliveryStatus
See UCP error codes chapter Delivery Status section for list of possible values.
int ReasonCode
See UCP error codes chapter Reason Code section for list of possible values.
string Content
In some configurations contains additional information or commentary on error codes returned.
TDateTime TimeStamp
If DeliveryStatus denotes correct message delivery, time TimeStamp denotes message delivery time. If the value returned by DeliveryStatus denotes message delivery failure than TimeStamp denotes the time of the last attempt to deliver the message.

See Also

ucpStatusReportReceivedEvent, ucpStatusReportReceivedEventArgs

OnUcpQueryResponseReceived

Event triggered on receive of response to ucpQueryMessage function.

public delegate void ucpQueryResponseReceivedEvent(Object Sender, ucpQueryResponseReceivedEventArgs e);

Description

Parameters

Sender

Object sending the event.

e

Object encapsulating event parameters.

uint TransactionNumber
Allows matching the response with command started with ucpQueryMessage function.
int ErrorCode
See UCP Error Codes section for list of possible values. Error Code defined as in UCP (7.1).
string SystemMessage
In some configurations contains additional information or commentary on error code returned.

See Also

ucpQueryMessage, ucpQueryResponseReceivedEvent, ucpQueryResponseReceivedEventArgs

OnUcpDeleteResponseReceived

Event triggered on receive of response to ucpDeleteMessage function.

public delegate void ucpDeleteResponseReceivedEvent(Object Sender, ucpDeleteResponseReceivedEventArgs e);

Description

Parameters

Sender

Object sending the event.

e

Object encapsulating event parameters.

uint TransactionNumber
Allows matching the response with command started with [ucpDeleteMessage](SMSCclientUCP::ucpDeleteMessage) function.
int ErrorCode
See UCP Error Codes section for list of possible values. Error Code defined as in UCP (7.1).
string SystemMessage
In some configurations contains additional information or commentary on error code returned.

See Also

ucpDeleteMessage, ucpDeleteResponseReceivedEvent, ucpDeleteResponseReceivedEventArgs

OnUcpTraceProtocol

Event triggered on every UCP protocol message exchanged between component and the SMSC.

public delegate void ucpTraceProtocolCallback(Object Sender, ucpTraceProtocolCallbackArgs e);

Description

This event allows to log all messages exchanged on the UCP protocol level between the component and the SMSC. Protocol messages are passed as hexadecimally encoded Protocol Data Units (PDU) which is exact binary representation of protocol message.

Parameters

Sender

Some sender description

e

Event parameters

string FromAddress
Colon separated IP address and port number (IP:Port).
string ToAddress
Colon separated IP address and port number (IP:Port).
int TransactionNumber
Identifier of the request/response sequence exchanged between UCP client and server. Response should have the same Sequence Number as request. Sequence Numbers are generated independently by client and server and should be unique for each peer.
int Operation
This field identifies tells wheather package contains operation or response.
int OperationType
This field identifies type of particular UCP message which indicates what operation data is contained within Protocol Data Unit (PDU).
string PDU
Protocol Data Unit (PDU) message data in hexadecimal representation (each two hexadecimal digits represent one byte of data).

See Also

ucpTraceProtocolCallbackArgs, ucpTraceProtocolCallback

Properties

Connected

Returns information on connection state.

public bool Connected { get; }

Description

If property is true then connection state on TCP/IP level is connected. If property is false then connection has been disconnected on TCP/IP level. Property is useful in implementing various reconnect scenarios.

KeepAliveInterval

Connection keep-alive timing.

public int KeepAliveInterval { get; set; }

Description

Value in seconds denoting time interval between packages keeping the connection alive in case no other packages are exchanged with the SMSC. It should be set according to the SMSC operator's instructions and the speed of Internet connection between the component and the SMSC. Typically, this value amounts to one third of the time after which the SMSC breaks the connection in case of lack of activity. When set to zero keep alive packets are never sent to the SMSC.

KeepAliveOperation

Protocol operation used to provide Keep Alive functionality.

public ucpKeepAliveOperationEnum KeepAliveOperation { get; set; }

Description

Value of this property determines which operation will be used by the component to implement the keep alive functionality. Accepted values of ucpKeepAliveOperationEnum are:

aoSMTAlert Connection is keep alive by using the OT-31 (SMT Alert Operation) message.
aoPhantomCallInput Connection is keep alive by using the OT-01 (Call Input Operation) message.

ResponseTimeOut

Communication timeout.

public int ResponseTimeOut { get; set; }

Description

Time in seconds, which determines maximum time the component will wait for response from the SMSC. It concerns all protocol level functions. After this time the function returns error code denoting operation timeout.

ImmediateResponse

Status report confirmation mode.

public bool ImmediateResponse { get; set; }

Description

Property decides whether ucpStatusReportReceivedEvent event confirms receive of the status report to the SMSC before (true) or after (false) execution of user code in the event handler. If the report is confirmed before SMSC may initiate another status report delivery faster. Contrarywise in the report is confirmed after, if user code inside event fails the status report is not confirmed and will be repeated by the SMSC within some time.

ThrottleRate

Message throttling limit parameter.

public int ThrottleRate { get; set; }

Description

Determines maximum rate of messages submitted to the SMSC per second. If set to any value above 0 component counts number of messages submitted and limits the rate by waiting appropriate time inside ucpSubmitMessage, ucpSubmitMessageEx, ucpSubmitMessageAsync functions. If the value is set to zero component does not limit the rate of messages submitted.