CSmsPDU Class Reference

class CSmsPDU : public CBase

A generic interface to a GSM SMS PDU.

The class can be used on its own to encode GSM SMS PDUs. It is also the base class for the six real implementations of GSM SMS PDUs. The derived classes are built up from the elements defined in gsmuelem.h according to the ETSI GSM 03.40. All the SMS elements have generic encode and decode functions so that each PDU type knows how to encode and decode itself into a TGsmSms .

CSmsPDU and derived classes provide a human readable interface to a GSM SMS PDU, for example setting the destination address on a SUBMIT ( CSmsSubmit ). All the factory functions for CSmsPDUs are provided in the base class.

Inherits from

Public Member Functions
IMPORT_C TSmsDataCodingScheme::TSmsAlphabet Alphabet ()
IMPORT_C TBool ApplicationPortAddressing ( TInt &, TInt &, TBool *)
IMPORT_C TSmsDataCodingScheme::TSmsDCSBits7To4 Bits7To4 ()
IMPORT_C TBool Class ( TSmsDataCodingScheme::TSmsClass &)
IMPORT_C TInt ConcatenatedMessagePDUIndex ()
IMPORT_C TInt ConcatenatedMessageReference ()
IMPORT_C TBool DataCodingSchemePresent ()
void DecodeL ( TGsmuLex8 &)
IMPORT_C CSmsPDU * DuplicateL ()
IMPORT_C void EncodeMessagePDUL ( TGsmSms &)
void EncodeMessagePDUL ( TGsmSms &, const TEncodeParams *)
IMPORT_C void ExternalizeL ( RWriteStream &)
IMPORT_C TSmsDataCodingScheme::TSmsIndicationState IndicationState ()
IMPORT_C TSmsDataCodingScheme::TSmsIndicationType IndicationType ()
IMPORT_C TSmsEncoding NationalLanguageEncoding ()
IMPORT_C CSmsPDU * NewL ( RReadStream &, CCnvCharacterSetConverter &, RFs &)
IMPORT_C CSmsPDU * NewL (const TGsmSms &, CCnvCharacterSetConverter &, RFs &, TBool , TBool )
IMPORT_C CSmsPDU * NewL ( TSmsPDUType , CCnvCharacterSetConverter &, RFs &, TBool )
IMPORT_C TInt NumConcatenatedMessagePDUs ()
IMPORT_C TSmsProtocolIdentifier::TSmsPIDType PIDType ()
IMPORT_C void ParsedServiceCenterAddress ( TGsmSmsTelNumber &)
IMPORT_C void ParsedToFromAddress ( TGsmSmsTelNumber &)
IMPORT_C TBool ProtocolIdentifierPresent ()
IMPORT_C TPtrC ServiceCenterAddress ()
IMPORT_C void SetAlphabet ( TSmsDataCodingScheme::TSmsAlphabet )
IMPORT_C void SetApplicationPortAddressingL ( TBool , TInt , TInt , TBool )
IMPORT_C void SetBits7To4 ( TSmsDataCodingScheme::TSmsDCSBits7To4 )
IMPORT_C void SetClass ( TBool , TSmsDataCodingScheme::TSmsClass )
IMPORT_C void SetConcatenatedMessagePDUIndex ( TInt )
IMPORT_C void SetConcatenatedMessageReference ( TInt )
IMPORT_C void SetDataCodingSchemePresent ( TBool )
IMPORT_C void SetIndicationState ( TSmsDataCodingScheme::TSmsIndicationState )
IMPORT_C void SetIndicationType ( TSmsDataCodingScheme::TSmsIndicationType )
IMPORT_C void SetNationalLanguageEncodingL ( TSmsEncoding )
IMPORT_C void SetNumConcatenatedMessagePDUs ( TInt )
IMPORT_C void SetPIDType ( TSmsProtocolIdentifier::TSmsPIDType )
IMPORT_C void SetParsedServiceCenterAddressL (const TGsmSmsTelNumber &)
IMPORT_C void SetParsedToFromAddressL (const TGsmSmsTelNumber &)
IMPORT_C void SetProtocolIdentifierPresent ( TBool )
IMPORT_C void SetServiceCenterAddressL (const TDesC &)
IMPORT_C void SetShortMessageType ( TSmsProtocolIdentifier::TSmsShortMessageType )
IMPORT_C void SetTelematicDeviceIndicator ( TSmsProtocolIdentifier::TSmsTelematicDeviceIndicator )
IMPORT_C void SetTelematicDeviceType ( TSmsProtocolIdentifier::TSmsTelematicDeviceType )
IMPORT_C void SetTextCompressed ( TBool )
IMPORT_C void SetTextConcatenatedL ( TBool , TBool )
IMPORT_C void SetToFromAddressL (const TDesC &)
IMPORT_C void SetUserDataPresent ( TBool )
IMPORT_C TSmsProtocolIdentifier::TSmsShortMessageType ShortMessageType ()
IMPORT_C TSmsProtocolIdentifier::TSmsTelematicDeviceIndicator TelematicDeviceIndicator ()
IMPORT_C TSmsProtocolIdentifier::TSmsTelematicDeviceType TelematicDeviceType ()
IMPORT_C TBool TextCompressed ()
IMPORT_C TBool TextConcatenated ( TBool *)
IMPORT_C TPtrC ToFromAddress ()
TSmsPDUType Type ()
void UpdateConcatenationDataL ( TInt , TInt , TInt )
void UpdateEmailHeaderDataL ( TInt &)
TBool UpdateSMSCCtrlParameterL (const TUint8 )
TBool UpdateTPSRRL ( TSmsFirstOctet )
IMPORT_C CSmsUserData & UserData ()
IMPORT_C const CSmsUserData & UserData ()
IMPORT_C TBool UserDataPresent ()
Protected Member Functions
CSmsPDU ( TSmsPDUType )
void ConstructL ( CCnvCharacterSetConverter &, RFs &)
const TSmsDataCodingScheme * DataCodingScheme ()
TUint8 * EncodeL ( TUint8 *)
TUint8 * EncodeL ( TUint8 *, const TEncodeParams *)
void ExternalizeMessagePDUL ( RWriteStream &)
void InternalizeMessagePDUL ( RReadStream &)
const TSmsParameterIndicator * ParameterIndicator ()
const TSmsProtocolIdentifier * ProtocolIdentifier ()
const CSmsAddress * ToFromAddressPtr ()
const CSmsUserData * UserDataPtr ()
Private Member Functions
TBool DoApplicationPortAddressing ( TInt &, TInt &, TInt &, TBool *)
void DoSetApplicationPortAddressingL ( TInt , TInt , TBool )
void DoSetTextConcatenatedL ( TBool )
TBool DoTextConcatenated ( TInt &, TBool *)
Inherited Functions
CBase::CBase()
CBase::Delete(CBase *)
CBase::Extension_(TUint,TAny *&,TAny *)
CBase::operator new(TUint)
CBase::operator new(TUint,TAny *)
CBase::operator new(TUint,TLeave)
CBase::operator new(TUint,TLeave,TUint)
CBase::operator new(TUint,TUint)
CBase::~CBase()
Public Member Enumerations
enum TSmsPDUType {
ESmsDeliver  = 0, ESmsDeliverReport  = 1, ESmsSubmit  = 2, ESmsSubmitReport  = 3, ESmsStatusReport  = 4, ESmsCommand  = 5
}
Protected Attributes
CSmsAddress * iServiceCenterAddress
Private Attributes
const TSmsPDUType iSmsPDUType

Constructor & Destructor Documentation

CSmsPDU(TSmsPDUType)

CSmsPDU ( TSmsPDUType aSmsPDUType ) [protected]

Parameters

TSmsPDUType aSmsPDUType

Member Functions Documentation

Alphabet()

IMPORT_C TSmsDataCodingScheme::TSmsAlphabet Alphabet ( ) const

Gets the alphabet encoded in the data coding scheme.

The function panics if the data coding scheme is not present.

capability
None

ApplicationPortAddressing(TInt &, TInt &, TBool *)

IMPORT_C TBool ApplicationPortAddressing ( TInt & aDestination,
TInt & aOriginator,
TBool * aIs16Bit = NULL
) const

Gets application port addressing information in the user data.

capability
None

Parameters

TInt & aDestination The destination port address
TInt & aOriginator The originating port address
TBool * aIs16Bit = NULL Set to true if the addressing is 16 bit. Default is null.

Bits7To4()

IMPORT_C TSmsDataCodingScheme::TSmsDCSBits7To4 Bits7To4 ( ) const

Gets bits 7 to 4 on the data coding scheme.

The value of bits 7 to 4 effects the meaning of the lower order bits.

The function panics if the data coding scheme is not present.

capability
None

Class(TSmsDataCodingScheme::TSmsClass &)

IMPORT_C TBool Class ( TSmsDataCodingScheme::TSmsClass & aClass ) const

Gets the GSM SMS PDU class in the data coding scheme.

The function panics if the data coding scheme is not present.

capability
None

Parameters

TSmsDataCodingScheme::TSmsClass & aClass Sms class 0 - 3 encoded in the data coding scheme

ConcatenatedMessagePDUIndex()

IMPORT_C TInt ConcatenatedMessagePDUIndex ( ) const

Gets the index of the PDU within the Concatenated Message.

The function panics if the PDU is not concatenated.

capability
None

ConcatenatedMessageReference()

IMPORT_C TInt ConcatenatedMessageReference ( ) const

Gets the reference contained in the Concatenation Information Element.

capability
None

ConstructL(CCnvCharacterSetConverter &, RFs &)

void ConstructL ( CCnvCharacterSetConverter & aCharacterSetConverter,
RFs & aFs
) [protected, pure virtual]

Parameters

CCnvCharacterSetConverter & aCharacterSetConverter
RFs & aFs

DataCodingScheme()

const TSmsDataCodingScheme * DataCodingScheme ( ) const [protected, virtual]

DataCodingSchemePresent()

IMPORT_C TBool DataCodingSchemePresent ( ) const

Tests if data coding scheme is present.

Panics if PDU type is unsupported.

capability
None

DecodeL(TGsmuLex8 &)

void DecodeL ( TGsmuLex8 & aPdu ) [pure virtual]

Parameters

TGsmuLex8 & aPdu

DoApplicationPortAddressing(TInt &, TInt &, TInt &, TBool *)

TBool DoApplicationPortAddressing ( TInt & aIndex,
TInt & aDestination,
TInt & aOriginator,
TBool * aIs16Bit
) const [private]

Parameters

TInt & aIndex
TInt & aDestination
TInt & aOriginator
TBool * aIs16Bit

DoSetApplicationPortAddressingL(TInt, TInt, TBool)

void DoSetApplicationPortAddressingL ( TInt aDestination,
TInt aOriginator,
TBool aIs16Bit
) [private]

Parameters

TInt aDestination
TInt aOriginator
TBool aIs16Bit

DoSetTextConcatenatedL(TBool)

void DoSetTextConcatenatedL ( TBool aIs16Bit ) [private]

Parameters

TBool aIs16Bit

DoTextConcatenated(TInt &, TBool *)

TBool DoTextConcatenated ( TInt & aIndex,
TBool * aIs16Bit
) const [private]

Parameters

TInt & aIndex
TBool * aIs16Bit

DuplicateL()

IMPORT_C CSmsPDU * DuplicateL ( ) const

Allocates and constructs a CSmsPDU as a copy of another CSmsPDU .

capability
None

EncodeL(TUint8 *)

TUint8 * EncodeL ( TUint8 * aPtr ) const [protected, pure virtual]

Parameters

TUint8 * aPtr

EncodeL(TUint8 *, const TEncodeParams *)

TUint8 * EncodeL ( TUint8 * aPtr,
const TEncodeParams * aEncodeParams
) const [protected, pure virtual]

Parameters

TUint8 * aPtr
const TEncodeParams * aEncodeParams

EncodeMessagePDUL(TGsmSms &)

IMPORT_C void EncodeMessagePDUL ( TGsmSms & aGsmSms ) const

Encodes a TGsmSms for the given type of CSmsPDU .

capability
None

Parameters

TGsmSms & aGsmSms On return, encoded GSM SMS PDU

EncodeMessagePDUL(TGsmSms &, const TEncodeParams *)

void EncodeMessagePDUL ( TGsmSms & aGsmSms,
const TEncodeParams * aEncodeParams
) const

Parameters

TGsmSms & aGsmSms
const TEncodeParams * aEncodeParams

ExternalizeL(RWriteStream &)

IMPORT_C void ExternalizeL ( RWriteStream & aStream ) const

Externalises the object.

capability
None

Parameters

RWriteStream & aStream Stream to write to

ExternalizeMessagePDUL(RWriteStream &)

void ExternalizeMessagePDUL ( RWriteStream & aStream ) const [protected, pure virtual]

Parameters

RWriteStream & aStream

IndicationState()

IMPORT_C TSmsDataCodingScheme::TSmsIndicationState IndicationState ( ) const

Gets the Indication State encoded in the data coding scheme.

The function panics if the data coding scheme is not present.

capability
None

IndicationType()

IMPORT_C TSmsDataCodingScheme::TSmsIndicationType IndicationType ( ) const

Gets the Indication Type encoded in the data coding scheme.

The function panics if the data coding scheme is not present.

capability
None

InternalizeMessagePDUL(RReadStream &)

void InternalizeMessagePDUL ( RReadStream & aStream ) [protected, pure virtual]

Parameters

RReadStream & aStream

NationalLanguageEncoding()

IMPORT_C TSmsEncoding NationalLanguageEncoding ( ) const

NewL(RReadStream &, CCnvCharacterSetConverter &, RFs &)

IMPORT_C CSmsPDU * NewL ( RReadStream & aStream,
CCnvCharacterSetConverter & aCharacterSetConverter,
RFs & aFs
) [static]

Restores a CSmsPDU from a stream where the object has bean previously persisted.

The type is determined from the first byte in the stream.

capability
None

Parameters

RReadStream & aStream Stream from which to restore this CSmsPDU
CCnvCharacterSetConverter & aCharacterSetConverter Character converter utility, required for encoding and decoding this PDU
RFs & aFs File system handle, required for encoding and decoding this PDU

NewL(const TGsmSms &, CCnvCharacterSetConverter &, RFs &, TBool, TBool)

IMPORT_C CSmsPDU * NewL ( const TGsmSms & aGsmSms,
CCnvCharacterSetConverter & aCharacterSetConverter,
RFs & aFs,
TBool aIsRPError = EFalse,
TBool aIsMobileTerminated = ETrue
) [static]

Allocates and constructs a CSmsPDU from a TGsmSms .

The type of SMS to construct is determined from the first octet in aGsmSms and whether the SMS is mobile terminated.

capability
None

Parameters

const TGsmSms & aGsmSms Encoded (raw) GSM SMS PDU
CCnvCharacterSetConverter & aCharacterSetConverter Character converter utility, required for encoding and decoding this PDU
RFs & aFs File system handle, required for encoding and decoding this PDU
TBool aIsRPError = EFalse True if the PDU is part of an RP Error. This is used only for SUBMIT REPORT (CSmsSubmitReport) and DELIVER REPORT (CSmsDeliverReport), as the format of these PDUs differs depending on whether the PDU is part of an RP Ack or RP Error.
TBool aIsMobileTerminated = ETrue Used to determine (with the first octet in aGsmSms) the TSmsPDUType

NewL(TSmsPDUType, CCnvCharacterSetConverter &, RFs &, TBool)

IMPORT_C CSmsPDU * NewL ( TSmsPDUType aType,
CCnvCharacterSetConverter & aCharacterSetConverter,
RFs & aFs,
TBool aIsRPError = EFalse
) [static]

Allocates and constructs a CSmsPDU , with the type specified by a TSmsPDUType.

capability
None

Parameters

TSmsPDUType aType The PDU type to construct
CCnvCharacterSetConverter & aCharacterSetConverter Character converter utility, required for encoding and decoding this PDU
RFs & aFs File system handle, required for encoding and decoding this PDU
TBool aIsRPError = EFalse True if the PDU is part of an RP Error. This is used only for SUBMIT REPORT (CSmsSubmitReport) and DELIVER REPORT (CSmsDeliverReport), as the format of these PDUs differs depending on whether the PDU is part of an RP Ack or RP Error.

NumConcatenatedMessagePDUs()

IMPORT_C TInt NumConcatenatedMessagePDUs ( ) const

Gets the number of PDU's in a Concatenated Message.

The function panics if the PDU is not concatenated.

capability
None

PIDType()

IMPORT_C TSmsProtocolIdentifier::TSmsPIDType PIDType ( ) const

Gets key bits 7 and 6 of the PID field.

capability
None

ParameterIndicator()

const TSmsParameterIndicator * ParameterIndicator ( ) const [protected, virtual]

ParsedServiceCenterAddress(TGsmSmsTelNumber &)

IMPORT_C void ParsedServiceCenterAddress ( TGsmSmsTelNumber & aParsedAddress ) const

Gets the service center address in a TGsmSmsTelNumber object.

A prepended '+', spaces and aphabetic characters are removed.

capability
None

Parameters

TGsmSmsTelNumber & aParsedAddress Service center address

ParsedToFromAddress(TGsmSmsTelNumber &)

IMPORT_C void ParsedToFromAddress ( TGsmSmsTelNumber & aParsedAddress ) const

Gets the "to from" in a TGsmSmsTelNumber object.

A prepended '+', spaces and aphabetic characters are removed.

capability
None

Parameters

TGsmSmsTelNumber & aParsedAddress The destination or sender address

ProtocolIdentifier()

const TSmsProtocolIdentifier * ProtocolIdentifier ( ) const [protected, virtual]

ProtocolIdentifierPresent()

IMPORT_C TBool ProtocolIdentifierPresent ( ) const

Tests if Protocol Identifier is present.

It panics if the PDU type is unsupported.

capability
None

ServiceCenterAddress()

IMPORT_C TPtrC ServiceCenterAddress ( ) const

Gets the service center address.

It is assumed that the address is Unicode, and can contain spaces and alphabetic characters.

capability
None

SetAlphabet(TSmsDataCodingScheme::TSmsAlphabet)

IMPORT_C void SetAlphabet ( TSmsDataCodingScheme::TSmsAlphabet aAlphabet )

Sets the alphabet encoded in the data coding scheme.

The function panics if the data coding scheme is not present.

capability
None

Parameters

TSmsDataCodingScheme::TSmsAlphabet aAlphabet Alphabet

SetApplicationPortAddressingL(TBool, TInt, TInt, TBool)

IMPORT_C void SetApplicationPortAddressingL ( TBool aAddressing,
TInt aDestination,
TInt aOriginator,
TBool aIs16Bit = EFalse
)

Sets application port addressing information in the user data.

capability
None

Parameters

TBool aAddressing If true, set application port addressing in the PDU. If false, removes addressing if it's already set
TInt aDestination The destination port address to set in the PDU
TInt aOriginator The originating port address to set in the PDU
TBool aIs16Bit = EFalse True if the addresses are 16 bit, false if 8 bit

SetBits7To4(TSmsDataCodingScheme::TSmsDCSBits7To4)

IMPORT_C void SetBits7To4 ( TSmsDataCodingScheme::TSmsDCSBits7To4 aBits7To4 )

Sets key bits 7 to 4 of the data coding scheme.

This is designed to be used for message waiting indication, as it is not needed for the normal type of data coding scheme where the alphabet and class are defined in the lower order bits.

The function panics if the data coding scheme is not present.

capability
None

Parameters

TSmsDataCodingScheme::TSmsDCSBits7To4 aBits7To4 Bits 7 to 4

SetClass(TBool, TSmsDataCodingScheme::TSmsClass)

IMPORT_C void SetClass ( TBool aClassDefined,
TSmsDataCodingScheme::TSmsClass aClass
)

Sets the GSM SMS PDU class in the data coding scheme.

The function panics if the data coding scheme is not present.

capability
None

Parameters

TBool aClassDefined True if SMS class is defined, else false
TSmsDataCodingScheme::TSmsClass aClass Sms class 0 - 3 encoded in the data coding scheme

SetConcatenatedMessagePDUIndex(TInt)

IMPORT_C void SetConcatenatedMessagePDUIndex ( TInt aIndex )

Sets the index of the PDU within the Concatenated Message.

The function panics if the PDU is not concatenated or aIndex is out of range.

capability
None

Parameters

TInt aIndex Index of the PDU within the Concatenated Message

SetConcatenatedMessageReference(TInt)

IMPORT_C void SetConcatenatedMessageReference ( TInt aReference )

Sets the reference contained in the Concatenation Information Element.

The function panics if aReference is out of range for the message type.

capability
None

Parameters

TInt aReference Value to set the Concatenated Message Reference.

SetDataCodingSchemePresent(TBool)

IMPORT_C void SetDataCodingSchemePresent ( TBool aPresent )

Sets if data coding scheme is present.

capability
None

Parameters

TBool aPresent True if data coding scheme is present

SetIndicationState(TSmsDataCodingScheme::TSmsIndicationState)

IMPORT_C void SetIndicationState ( TSmsDataCodingScheme::TSmsIndicationState aState )

Sets the Indication State encoded in the data coding scheme.

The function panics if the data coding scheme is not present.

capability
None

Parameters

TSmsDataCodingScheme::TSmsIndicationState aState Indication State

SetIndicationType(TSmsDataCodingScheme::TSmsIndicationType)

IMPORT_C void SetIndicationType ( TSmsDataCodingScheme::TSmsIndicationType aType )

Sets the Indication Type encoded in the data coding scheme.

The function panics if the data coding scheme is not present.

capability
None

Parameters

TSmsDataCodingScheme::TSmsIndicationType aType Indication Type

SetNationalLanguageEncodingL(TSmsEncoding)

IMPORT_C void SetNationalLanguageEncodingL ( TSmsEncoding aEncoding )

Parameters

TSmsEncoding aEncoding

SetNumConcatenatedMessagePDUs(TInt)

IMPORT_C void SetNumConcatenatedMessagePDUs ( TInt aNum )

Sets the number of PDU's in a Concatenated Message.

The function panics if the PDU is not concatenated or if aNum is out of range.

capability
None

Parameters

TInt aNum Number of PDU's in a Concatenated Message

SetPIDType(TSmsProtocolIdentifier::TSmsPIDType)

IMPORT_C void SetPIDType ( TSmsProtocolIdentifier::TSmsPIDType aSmsPIDType )

Sets key bits 7 and 6 of the PID field.

capability
None

Parameters

TSmsProtocolIdentifier::TSmsPIDType aSmsPIDType Bits 7 and 6 of the PID field

SetParsedServiceCenterAddressL(const TGsmSmsTelNumber &)

IMPORT_C void SetParsedServiceCenterAddressL ( const TGsmSmsTelNumber & aParsedAddress )

Sets the service center address through a TGsmSmsTelNumber object.

These functions panic for a DELIVER REPORT ( CSmsDeliverReport ) or a SUBMIT REPORT ( CSmsSubmitReport ).

capability
None

Parameters

const TGsmSmsTelNumber & aParsedAddress Service center address

SetParsedToFromAddressL(const TGsmSmsTelNumber &)

IMPORT_C void SetParsedToFromAddressL ( const TGsmSmsTelNumber & aParsedAddress )

Sets the "to from" with a TGsmSmsTelNumber object.

capability
None

Parameters

const TGsmSmsTelNumber & aParsedAddress The destination or sender address

SetProtocolIdentifierPresent(TBool)

IMPORT_C void SetProtocolIdentifierPresent ( TBool aPresent )

Sets if Protocol Identifier is present.

It panics if the PDU type is unsupported.

capability
None

Parameters

TBool aPresent True if Protocol Identifier is present

SetServiceCenterAddressL(const TDesC &)

IMPORT_C void SetServiceCenterAddressL ( const TDesC & aAddress )

Sets the service center address.

A prepended '+' is used to indicate an international number.

capability
None

Parameters

const TDesC & aAddress Service center address

SetShortMessageType(TSmsProtocolIdentifier::TSmsShortMessageType)

IMPORT_C void SetShortMessageType ( TSmsProtocolIdentifier::TSmsShortMessageType aShortMessageType )

Sets the Short Message Type in the PID field.

capability
None

Parameters

TSmsProtocolIdentifier::TSmsShortMessageType aShortMessageType Short Message Type

SetTelematicDeviceIndicator(TSmsProtocolIdentifier::TSmsTelematicDeviceIndicator)

IMPORT_C void SetTelematicDeviceIndicator ( TSmsProtocolIdentifier::TSmsTelematicDeviceIndicator aIndicator )

Sets the Telematic device indicator from the PID field.

capability
None

Parameters

TSmsProtocolIdentifier::TSmsTelematicDeviceIndicator aIndicator Telematic device indicator

SetTelematicDeviceType(TSmsProtocolIdentifier::TSmsTelematicDeviceType)

IMPORT_C void SetTelematicDeviceType ( TSmsProtocolIdentifier::TSmsTelematicDeviceType aDeviceType )

Sets the Telematic device type in the PID field.

capability
None

Parameters

TSmsProtocolIdentifier::TSmsTelematicDeviceType aDeviceType Telematic device type

SetTextCompressed(TBool)

IMPORT_C void SetTextCompressed ( TBool aCompressed )

Set to encode Text Compressed in the data coding scheme.

The function panics if the data coding scheme is not present.

capability
None

Parameters

TBool aCompressed True to encode Text Compressed

SetTextConcatenatedL(TBool, TBool)

IMPORT_C void SetTextConcatenatedL ( TBool aConcatenated,
TBool aIs16Bit = EFalse
)

Sets whether the PDU is part of a concatenated message or not.

It is a leaving function as it is inserting an information element into the user data.

capability
None

Parameters

TBool aConcatenated True if message is concatenated
TBool aIs16Bit = EFalse True if type of Concatenation Information Element is 16 bit

SetToFromAddressL(const TDesC &)

IMPORT_C void SetToFromAddressL ( const TDesC & aAddress )

Sets the "to from" address.

The function panics for a DELIVER REPORT ( CSmsDeliverReport ) or a SUBMIT REPORT ( CSmsSubmitReport ).

A prepended '+' is used to indicate an international number.

capability
None

Parameters

const TDesC & aAddress The destination or sender address

SetUserDataPresent(TBool)

IMPORT_C void SetUserDataPresent ( TBool aPresent )

Sets or unsets the User Data Header Indicator.

It panics if PDU type is unsupported.

capability
None

Parameters

TBool aPresent True to set the User Data Header Indicator

ShortMessageType()

IMPORT_C TSmsProtocolIdentifier::TSmsShortMessageType ShortMessageType ( ) const

Gets the Short Message Type in the PID field.

capability
None

TelematicDeviceIndicator()

IMPORT_C TSmsProtocolIdentifier::TSmsTelematicDeviceIndicator TelematicDeviceIndicator ( ) const

Gets the Telematic device indicator from the PID field.

capability
None

TelematicDeviceType()

IMPORT_C TSmsProtocolIdentifier::TSmsTelematicDeviceType TelematicDeviceType ( ) const

Gets the Telematic device type in the PID field.

capability
None

TextCompressed()

IMPORT_C TBool TextCompressed ( ) const

True if Text Compressed is encoded in the data coding scheme.

The function panics if the data coding scheme is not present.

capability
None

TextConcatenated(TBool *)

IMPORT_C TBool TextConcatenated ( TBool * aIs16Bit = NULL ) const

Tests if the PDU is part of a concatenated message.

capability
None

Parameters

TBool * aIs16Bit = NULL Content is set true if Concatenation Information Element is 16-bit. Default is null.

ToFromAddress()

IMPORT_C TPtrC ToFromAddress ( ) const

Gets the "to from" address.

This address is the original (sender's) address for a DELIVER ( CSmsDeliver ), the destination address for a SUBMIT ( CSmsSubmit ), the recipient (sender's) address for a STATUS REPORT ( CSmsStatusReport ) and the destination address for a COMMAND ( CSmsCommand ).

The function panics for a DELIVER REPORT ( CSmsDeliverReport ) or a SUBMIT REPORT ( CSmsSubmitReport ).

It is assumed that the address is Unicode, and can contain spaces and alphabetic characters.

capability
None

ToFromAddressPtr()

const CSmsAddress * ToFromAddressPtr ( ) const [protected, virtual]

Type()

TSmsPDUType Type ( ) const [inline]

UpdateConcatenationDataL(TInt, TInt, TInt)

void UpdateConcatenationDataL ( TInt aRef,
TInt aPduIndex,
TInt aMaxPdu
)

Updates the three pieces of concatenation data (reference number, pdu index and max pdu number) in this PDU.

Parameters

TInt aRef Reference number.
TInt aPduIndex Current PDU number.
TInt aMaxPdu Total PDU number.

UpdateEmailHeaderDataL(TInt &)

void UpdateEmailHeaderDataL ( TInt & aEmailOverallHeaderLength )

Updates the email header data in this PDU.

Parameters

TInt & aEmailOverallHeaderLength Length of the email header.

UpdateSMSCCtrlParameterL(const TUint8)

TBool UpdateSMSCCtrlParameterL ( const TUint8 aOctet )

Updates the SMSC control parameter in this PDU.

Parameters

const TUint8 aOctet Value to store in the SMSC control parameter.

UpdateTPSRRL(TSmsFirstOctet)

TBool UpdateTPSRRL ( TSmsFirstOctet aSmsReportRequest )

Updates the TPSRRL control parameter in this PDU.

Parameters

TSmsFirstOctet aSmsReportRequest Status Report Request setting.

UserData()

IMPORT_C CSmsUserData & UserData ( )

Gets User Data (non-const).

capability
None

UserData()

IMPORT_C const CSmsUserData & UserData ( ) const

Gets User Data (const).

capability
None

UserDataPresent()

IMPORT_C TBool UserDataPresent ( ) const

Tests if the User Data Header Indicator is set.

It panics if PDU type is unsupported.

capability
None

UserDataPtr()

const CSmsUserData * UserDataPtr ( ) const [protected, virtual]

Member Enumerations Documentation

Enum TSmsPDUType

Flags for the 6 basic PDU types in GSM SMS messaging.

Enumerators

ESmsDeliver = 0
ESmsDeliverReport = 1
ESmsSubmit = 2
ESmsSubmitReport = 3
ESmsStatusReport = 4
ESmsCommand = 5

Member Data Documentation

CSmsAddress * iServiceCenterAddress

CSmsAddress * iServiceCenterAddress [protected]

const TSmsPDUType iSmsPDUType

const TSmsPDUType iSmsPDUType [private]