class CSmsMessage : public CBase |
Represents a complete SMS message.
This class can:
Internalise and externalise its data
Encode/decode itself to/from one or more SMS PDU's
SMS Message Data is stored in the CSmsBufferBase iBuffer. SMS Message Settings are stored in the CSmsPDU iSmsPDU.
Public Member Enumerations | |
---|---|
enum | TMobileSmsStorage { ESmsNoStorage = 0x00, ESmsSIMStorage = 0x04, ESmsPhoneStorage = 0x08, ESmsCombinedStorage = 0x0C } |
enum | TSmsMessageVersion { ESmsMessageV0, ESmsMessageV1, ESmsMessageV2, ESmsMessageV3, ESmsIncompleteClass0MessageV = ESmsMessageV3, ESmsMessageV4 } |
enum | TSmsOptimizationFlags { ESmsFlagOptimizeAlphabet = 0x01, ESmsFlagOptimizeConcatenation = 0x08, ESmsFlagOptimizeConcatenation16BitReference = 0x10 } |
enum | TTimeIntervalsRepresentedInSeconds { E15MinutesRepresentedInSeconds = 15 * 60, EMaximumSeconds = 79 * E15MinutesRepresentedInSeconds } |
Private Member Enumerations | |
---|---|
enum | TDecodedOnSimBit { EDecodedOnSimBit = 0x80000000 } |
enum | TForwardToClientBit { EForwardToClientBit = 0x40000000 } |
enum | TSmsMessageFlags { ESmsFlagIsComplete = 0x01, ESmsFlagIsDecoded = 0x02, ESmsStorageMask = 0x0C, ESmsUTCOffsetSecondGranularityMask = 0x1FFFF0, ESmsUTCOffsetSignBit = 0x200000 } |
enum | TTimeBitMaskOffsets { ESecondBitOffset = 4, ESignBitOffset = 21 } |
Public Attributes | |
---|---|
CArrayFixFlat< TGsmSmsSlotEntry > | iSlotArray |
Protected Attributes | |
---|---|
CSmsMessageAdditionalAttributes * | iAdditionalInfo |
TInt | iVersion |
CSmsMessage | ( | RFs & | aFs, |
CSmsBufferBase * | aBuffer | ||
) | [private] |
RFs & aFs | |
CSmsBufferBase * aBuffer |
void | AddControlInformationElementsToMultiSegmentMessageL | ( | TBool | aDoEncode | ) | [private] |
TBool aDoEncode |
void | AddControlInformationElementsToMultiSegmentMessageL | ( | TSmsInformationElementCategories::TInformationElementCategory | aCategory, |
TBool | aMandatoryInPDU, | |||
TBool | aDoEncode | |||
) | [private] |
TSmsInformationElementCategories::TInformationElementCategory aCategory | |
TBool aMandatoryInPDU | |
TBool aDoEncode |
void | AddCurrentPDUToPDUArrayL | ( | TBool | aDoEncode | ) | [private] |
TBool aDoEncode |
IMPORT_C void | AddEMSInformationElementL | ( | const CEmsInformationElement & | aEmsIE | ) |
const CEmsInformationElement & aEmsIE |
TBool | AddEMSInformationElementsToMultiSegmentMessageL | ( | CSmsEMSBufferSegmenter & | aSegmenter, |
TUint & | aCharsAdded, | |||
TBool | aDoEncode, | |||
TSmsEncoding & | aEncoding, | |||
RPointerArray< CEmsInformationElement > & | aCorrectedFormatingIEArray, | |||
TUint & | aCurEMSIEno, | |||
TUint & | aBaseAddr | |||
) | [private] |
CSmsEMSBufferSegmenter & aSegmenter | |
TUint & aCharsAdded | |
TBool aDoEncode | |
TSmsEncoding & aEncoding | |
RPointerArray< CEmsInformationElement > & aCorrectedFormatingIEArray | |
TUint & aCurEMSIEno | |
TUint & aBaseAddr |
TBool | AddEMSInformationElementsToSingleSegmentMessageL | ( | CSmsEMSBufferSegmenter & | aSegmenter, |
TSmsEncoding | aEncoding | |||
) | [private] |
CSmsEMSBufferSegmenter & aSegmenter | |
TSmsEncoding aEncoding |
IMPORT_C void | AddEmailHeaderL | ( | const TDesC & | aEmailHeader, |
const TDesC & | aEmailBody | |||
) |
void | AddEmsObjectDistributionL | ( | const CEmsObjectDistribution & | aObjectDistributionIE | ) | [private] |
const CEmsObjectDistribution & aObjectDistributionIE |
void | AddEmsUserPromptL | ( | const CEmsUserPrompt & | aEmsIE | ) | [private] |
const CEmsUserPrompt & aEmsIE |
TBool | AddIEToUserDataL | ( | CEmsInformationElement * | aIe, |
TInt | aCharsAlreadyAdded, | |||
TUint & | aCharsAddedToCurrentPDU, | |||
CSmsEMSBufferSegmenter & | aSeg | |||
) | [private] |
CEmsInformationElement * aIe | |
TInt aCharsAlreadyAdded | |
TUint & aCharsAddedToCurrentPDU | |
CSmsEMSBufferSegmenter & aSeg |
void | AddIncompleteMessageInfoL | ( | TInt | aStartPDU, |
TInt | aEndPDU, | |||
TBool | aLastPartialCompleteMsg | |||
) | [private] |
TInt | AddReceivedEmsInformationElement | ( | CEmsInformationElement * | aIE | ) | [private] |
CEmsInformationElement * aIE |
IMPORT_C void | AddSlotL | ( | const TGsmSmsSlotEntry & | aSlot | ) |
const TGsmSmsSlotEntry & aSlot |
CSmsBufferBase & | Buffer | ( | ) | [inline] |
Gets the text portion of the message (non-const).
Text portion of the message
TBool | CanBeRemoved | ( | const CEmsInformationElement & | aIE, |
TUint | aIEIndex | |||
) | [private] |
const CEmsInformationElement & aIE | |
TUint aIEIndex |
void | ConstructL | ( | const TGsmSms & | aGsmSms, |
TBool | aIsRPError, | |||
TBool | aIsMobileTerminated | |||
) | [private] |
void | ConstructL | ( | CSmsPDU::TSmsPDUType | aType, |
TBool | aIsRPError | |||
) | [private] |
CSmsPDU::TSmsPDUType aType | |
TBool aIsRPError |
TInt | ConvertedBufferLengthL | ( | const CSmsBufferBase & | aBuffer | ) | [private] |
const CSmsBufferBase & aBuffer |
IMPORT_C void | CopyEmsElementsL | ( | CSmsMessage & | aToMessage | ) | const |
CSmsMessage & aToMessage |
void | CorrectFormattingL | ( | TUint | aCharsAddedToCurrentPDU, |
RPointerArray< CEmsInformationElement > & | aCorrectedFormatingIEArray, | |||
TUint | aBaseAddr | |||
) | [private] |
TUint aCharsAddedToCurrentPDU | |
RPointerArray< CEmsInformationElement > & aCorrectedFormatingIEArray | |
TUint aBaseAddr |
void | DecodeBufferL | ( | CArrayPtr< CSmsPDU > & | aSmsPDUArray, |
CSmsBufferBase & | aBuffer | |||
) | [private] |
CArrayPtr< CSmsPDU > & aSmsPDUArray | |
CSmsBufferBase & aBuffer |
IMPORT_C void | DecodeMessagePDUsL | ( | const CArrayFix< TGsmSms > & | aSmsArray | ) |
void | DecodeOnlyTextL | ( | CArrayPtr< CSmsPDU > & | aSmsPDUArray, |
CSmsBufferBase & | aBuffer | |||
) | [private] |
CArrayPtr< CSmsPDU > & aSmsPDUArray | |
CSmsBufferBase & aBuffer |
IMPORT_C void | DecodePartialCompleteMessagePDUsL | ( | const CArrayFix< TGsmSms > & | aSmsArray, |
TBool | aLastPartialCompleteMsg | |||
) |
void | EncodeBufferL | ( | CArrayFix< TGsmSms > & | aSmsArray, |
TInt | aReference, | |||
const CSmsBufferBase & | aBuffer, | |||
TInt & | aUnconvertedChars, | |||
TInt & | aDowngradedChars, | |||
TInt & | aFreeUDUnitsInLastPDU, | |||
TBool | aDoEncode = ETrue | |||
) | [private] |
IMPORT_C TBool | EncodeIntoSinglePDUL | ( | CArrayFix< TGsmSms > & | aSmsArray | ) |
TBool | EncodeIntoSinglePDUL | ( | CArrayFix< TGsmSms > & | aSmsArray, |
TInt & | aUnconvertedChars, | |||
TInt & | aDowngradedChars, | |||
TInt & | aFreeUDUnitsInLastPDU | |||
) | [private] |
IMPORT_C void | EncodeMessagePDUsL | ( | CArrayFix< TGsmSms > & | aSmsArray, |
TInt | aReference = 0 | |||
) |
IMPORT_C void | ExternalizeBufferL | ( | RWriteStream & | aStream | ) | const |
RWriteStream & aStream |
IMPORT_C void | ExternalizeL | ( | RWriteStream & | aStream | ) | const |
RWriteStream & aStream |
IMPORT_C void | ExternalizeVersionL | ( | RWriteStream & | aStream | ) | const |
RWriteStream & aStream |
IMPORT_C void | ExternalizeWithoutBufferAndVersionL | ( | RWriteStream & | aStream | ) | const |
RWriteStream & aStream |
IMPORT_C void | ExternalizeWithoutBufferL | ( | RWriteStream & | aStream | ) | const |
RWriteStream & aStream |
TInt | FillPduL | ( | CSmsEMSBufferSegmenter & | aSeg, |
TInt | aNumChars, | |||
TSmsEncoding | aEncoding | |||
) | [private] |
CSmsEMSBufferSegmenter & aSeg | |
TInt aNumChars | |
TSmsEncoding aEncoding |
TSmsStatusReportScheme | FindSchemeL | ( | const CArrayPtr< CSmsPDU > & | aSmsPDUArray | ) | [private] |
IMPORT_C const RPointerArray< const CEmsInformationElement > & | GetEMSInformationElementsL | ( | ) | const |
IMPORT_C TBool | GetEmailHeaderL | ( | HBufC ** | aEmailHeader, |
HBufC ** | aEmailBody | |||
) |
IMPORT_C void | GetEncodingInfoL | ( | TInt & | aPdus, |
TInt & | aUnconvertedChars, | |||
TInt & | aDowngradedChars, | |||
TInt & | aFreeUDUnitsInLastPDU | |||
) |
IMPORT_C CSmsIEOperation & | GetOperationsForIEL | ( | CSmsInformationElement::TSmsInformationElementIdentifier | ) | const |
IMPORT_C CSmsNonIEOperation & | GetOperationsForNonIEL | ( | TSmsNonIEIdentifier | ) | const |
TSmsNonIEIdentifier |
void | InstallControlInformationElementsL | ( | CSmsUserData & | aUserData, |
TInt | aSegmentSequenceNum | |||
) | [private] |
CSmsUserData & aUserData | |
TInt aSegmentSequenceNum |
void | InstallControlInformationElementsL | ( | CSmsCommand & | aCommand | ) | [private] |
CSmsCommand & aCommand |
void | InstallEmailHeaderInformationElementL | ( | CSmsUserData & | aUserData, |
TInt & | aHeaderLength | |||
) |
CSmsUserData & aUserData | |
TInt & aHeaderLength |
void | InstallEmailHeaderInformationElementL | ( | CSmsCommand & | aCommand, |
TInt & | aHeaderLength | |||
) |
CSmsCommand & aCommand | |
TInt & aHeaderLength |
void | InstallEmsInformationElementsL | ( | CSmsUserData & | aUserData, |
TInt | aStartPosition | |||
) | [private] |
CSmsUserData & aUserData | |
TInt aStartPosition |
void | InstallEmsInformationElementsL | ( | CSmsCommand & | aCommand, |
TInt | aStartPosition | |||
) | [private] |
CSmsCommand & aCommand | |
TInt aStartPosition |
void | InstallTPSRRInformationL | ( | const CArrayPtr< CSmsPDU > & | aSmsPDUArray, |
TInt | aSegmentSequenceNum | |||
) | [private] |
IMPORT_C void | InternalizeBufferL | ( | RReadStream & | aStream | ) |
RReadStream & aStream |
IMPORT_C void | InternalizeL | ( | RReadStream & | aStream | ) |
RReadStream & aStream |
IMPORT_C void | InternalizeVersionL | ( | RReadStream & | aStream | ) |
RReadStream & aStream |
IMPORT_C void | InternalizeWithoutBufferAndVersionL | ( | RReadStream & | aStream | ) |
RReadStream & aStream |
IMPORT_C void | InternalizeWithoutBufferL | ( | RReadStream & | aStream | ) |
RReadStream & aStream |
TBool | IsComplete | ( | ) | const [inline] |
Tests if the SMS message is complete.
True if complete
IMPORT_C TBool | IsSupportedL | ( | const TDesC & | aDes, |
TInt & | aNumberOfUnconvertibleCharacters, | |||
TInt & | aIndexOfFirstUnconvertibleCharacter | |||
) |
IMPORT_C TBool | IsSupportedL | ( | const TDesC & | aDes, |
TInt & | aNumberOfUnconvertibleCharacters, | |||
TInt & | aNumberOfDowngradedCharacters, | |||
TInt & | aNumberRequiringAlternativeEncoding, | |||
TInt & | aIndexOfFirstUnconvertibleCharacter | |||
) | const |
IMPORT_C TBool | MatchSlots | ( | const CArrayFixFlat< TGsmSmsSlotEntry > & | aSlotArray | ) |
const CArrayFixFlat< TGsmSmsSlotEntry > & aSlotArray |
void | MergeAlternative7bitEncoding | ( | TSmsEncoding | aEncoding | ) | const [private] |
TSmsEncoding aEncoding |
IMPORT_C CSmsMessage * | NewL | ( | RFs & | aFs, |
const TGsmSms & | aGsmSms, | |||
CSmsBufferBase * | aBuffer, | |||
TBool | aIsRPError = EFalse, | |||
TBool | aIsMobileTerminated = ETrue | |||
) | [static] |
RFs & aFs | |
const TGsmSms & aGsmSms | |
CSmsBufferBase * aBuffer | |
TBool aIsRPError = EFalse | |
TBool aIsMobileTerminated = ETrue |
IMPORT_C CSmsMessage * | NewL | ( | RFs & | aFs, |
CSmsPDU::TSmsPDUType | aType, | |||
CSmsBufferBase * | aBuffer, | |||
TBool | aIsRPError = EFalse | |||
) | [static] |
RFs & aFs | |
CSmsPDU::TSmsPDUType aType | |
CSmsBufferBase * aBuffer | |
TBool aIsRPError = EFalse |
void | ParsedServiceCenterAddress | ( | TGsmSmsTelNumber & | aParsedAddress | ) | const [inline] |
Gets the Service Center Address as an ETSI-formatted telephone number.
TGsmSmsTelNumber & aParsedAddress | Service Center Address |
void | ParsedToFromAddress | ( | TGsmSmsTelNumber & | aParsedAddress | ) | const [inline] |
Gets To and From addresses in ETSI format.
TGsmSmsTelNumber & aParsedAddress | To and From addresses |
IMPORT_C CEmsInformationElement * | RemoveEMSInformationElementL | ( | const TUint | aStartPosition, |
const TSmsId | aEmsId | |||
) |
IMPORT_C RPointerArray< CEmsInformationElement > * | RemoveEMSInformationElementsL | ( | const TUint | aStartPosition, |
const TSmsId | aEmsId | |||
) |
TPtrC | ServiceCenterAddress | ( | ) | const [inline] |
Gets the message Service Center Address.
Service Center Address
void | Set16BitConcatenation | ( | TBool | aIs16BitConcatenation | ) | [inline] |
TBool aIs16BitConcatenation |
IMPORT_C TInt | SetAlternative7bitEncoding | ( | TSmsEncoding | aEncoding | ) |
TSmsEncoding aEncoding |
void | SetIsComplete | ( | TBool | aIsComplete | ) | [private, inline] |
TBool aIsComplete | Set to True for CSmsMessage complete |
void | SetIsDecoded | ( | TBool | aIsDecoded | ) | [private, inline] |
TBool aIsDecoded | Set to True for CSmsMessage decoded |
void | SetLogServerId | ( | TInt | aId | ) | [inline] |
Sets the Log Server Id.
TInt aId | Log Server Id |
void | SetParsedServiceCenterAddressL | ( | const TGsmSmsTelNumber & | aParsedAddress | ) | [inline] |
Sets the Service Center Address as an ETSI-formatted telephone number.
const TGsmSmsTelNumber & aParsedAddress | Service Center Address |
void | SetParsedToFromAddressL | ( | const TGsmSmsTelNumber & | aParsedAddress | ) | [inline] |
Sets To and From addresses in ETSI format.
const TGsmSmsTelNumber & aParsedAddress | To and From addresses |
void | SetServiceCenterAddressL | ( | const TDesC & | aAddress | ) | [inline] |
Sets the message Service Center Address.
const TDesC & aAddress | Service Center Address |
void | SetStatus | ( | NMobileSmsStore::TMobileSmsStoreStatus | aStatus | ) | [inline] |
Sets the SMS store status of the message.
NMobileSmsStore::TMobileSmsStoreStatus aStatus | SMS store status |
void | SetStorage | ( | TMobileSmsStorage | aStorage | ) | [inline] |
Sets the physical location where the message represented by the object is stored.
TMobileSmsStorage aStorage | Physical location |
void | SetTime | ( | const TTime & | aTime | ) | [inline] |
Sets the time of message creation.
const TTime & aTime | Time of message creation |
void | SetToFromAddressL | ( | const TDesC & | aAddress | ) | [inline] |
Sets unparsed To and From addresses.
const TDesC & aAddress | To and From addresses |
IMPORT_C TBool | SetUTCOffset | ( | const TTimeIntervalSeconds & | aTimeOffset | ) |
const TTimeIntervalSeconds & aTimeOffset |
IMPORT_C void | SetUserDataSettingsL | ( | const TSmsUserDataSettings & | aSettings | ) |
const TSmsUserDataSettings & aSettings |
NMobileSmsStore::TMobileSmsStoreStatus | Status | ( | ) | const [inline] |
Gets the SMS store status of the message.
SMS store status
TMobileSmsStorage | Storage | ( | ) | const [inline] |
Gets the physical location where the message represented by the object is stored.
Physical location
const TTime & | Time | ( | ) | const [inline] |
Gets the time of message creation.
Time of message creation
TPtrC | ToFromAddress | ( | ) | const [inline] |
Gets unparsed To and From addresses.
To and From addresses
void | UpdateUserPromptAndODIElementsStartPosition | ( | ) | [private] |
IMPORT_C void | UserDataSettings | ( | TSmsUserDataSettings & | aSettings | ) | const |
TSmsUserDataSettings & aSettings |
Flags that indicate whether a message is stored.
ESmsNoStorage = 0x00 |
No storage. |
ESmsSIMStorage = 0x04 |
SIM storage. |
ESmsPhoneStorage = 0x08 |
Phone storage. |
ESmsCombinedStorage = 0x0C |
Combined storage. |
ESmsFlagIsComplete = 0x01 | |
ESmsFlagIsDecoded = 0x02 | |
ESmsStorageMask = 0x0C | |
ESmsUTCOffsetSecondGranularityMask = 0x1FFFF0 | |
ESmsUTCOffsetSignBit = 0x200000 |
SMS versions
ESmsMessageV0 |
The default value. |
ESmsMessageV1 |
Release 6 SMS Support |
ESmsMessageV2 |
Latest version |
ESmsMessageV3 |
Incomplete Class0 Information Support |
ESmsIncompleteClass0MessageV = ESmsMessageV3 | |
ESmsMessageV4 |
National language 7bit encoding support |
User data optimisation flags.
ESmsFlagOptimizeAlphabet = 0x01 |
The alphabet flag causes an alphabet to be chosen which preserves information in the message and makes the number of PDUs as small as possible. |
ESmsFlagOptimizeConcatenation = 0x08 |
8-bit referenced concatenation. This causes compression to be switched off and if the message length is greater than the maximum message length, concatenation is switched on. |
ESmsFlagOptimizeConcatenation16BitReference = 0x10 |
16-bit referenced concatenation. This causes compression to be switched off and if the message length is greater than the maximum message length, concatenation is switched on. |
E15MinutesRepresentedInSeconds = 15 * 60 | |
EMaximumSeconds = 79 * E15MinutesRepresentedInSeconds |
CSmsMessageAdditionalAttributes * | iAdditionalInfo | [protected] |
iAdditionalInfo would point to any new added data structure. iVersion would identify which data structure is valid for that * particular version of CSmsMessage
CCnvCharacterSetConverter * | iCharacterSetConverter | [private] |
RPointerArray< CEmsInformationElement > * | iInformationElementArray | [private] |
NMobileSmsStore::TMobileSmsStoreStatus | iStatus | [private] |
TInt | iVersion | [protected] |
iVersion is the version of CSmsMessage. This parameter will be used to identify what iAdditionalInfo points to for that particular version of CSmsMessage