1 // Copyright (c) 1999-2009 Nokia Corporation and/or its subsidiary(-ies).
2 // All rights reserved.
3 // This component and the accompanying materials are made available
4 // under the terms of the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members
5 // which accompanies this distribution, and is available
6 // at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
8 // Initial Contributors:
9 // Nokia Corporation - initial contribution.
23 The type of operation for which progress information is being given.
25 inline TSmsProgress::TSmsProgress(TSmsProgressType aType)
35 iServiceCenterAddress.Zero();
39 Gets the validity period for messages sent by the SMS MTM.
41 If the service centre is unable to deliver the SMS message before this time
42 expires, a failure report may be generated by the service centre, and no further
43 attempts will be made to deliver the message to ther recipient.
45 Validity period is only used for SMS-SUBMIT, mobile originated messages.
48 The validity period of the message.
50 inline const TTimeIntervalMinutes& CSmsMessageSettings::ValidityPeriod() const
52 return iValidityPeriod;
56 Sets the validity period for messages sent by the SMS MTM.
58 @param aValidityPeriod
62 The validity period is negative or greater than the maximum validity period
65 inline void CSmsMessageSettings::SetValidityPeriod(TTimeIntervalMinutes aValidityPeriod)
67 __ASSERT_DEBUG(aValidityPeriod.Int()>=0 && aValidityPeriod.Int()<=ESmsVPMaximum,Panic(ESmscVPOutOfRange));
68 iValidityPeriod=aValidityPeriod;
72 Gets the values of the UI concatenated-SMS-allowed flag.
74 If true, the UI should pass a long message in one piece to the MTM. If false,
75 it should split the message manually into 140 byte parts. The value of this
76 flag does not affect the behaviour of the SMS MTM.
79 The concatenated-SMS-allowed flag.
81 inline TBool CSmsMessageSettings::CanConcatenate() const
83 return iMsgFlags&ESmsSettingsCanConcatenate;
87 Sets the values of the UI concatenated-SMS-allowed flag.
89 If true, the UI should pass a long message in one piece to the MTM. If false,
90 it should split the message manually into 140 byte parts. The value of this
91 flag does not affect the behaviour of the SMS MTM.
93 @param aCanConcatenate
94 The value to set the concatenated-SMS-allowed flag to.
96 inline void CSmsMessageSettings::SetCanConcatenate(TBool aCanConcatenate)
98 iMsgFlags = (iMsgFlags & ~ESmsSettingsCanConcatenate) | (aCanConcatenate?ESmsSettingsCanConcatenate : ESmsSettingsNoFlags);
102 Gets the value of the reject-duplicate setting.
104 If this is true, the service instructs the SC to reject an Sms-Submit for an
105 SMS still held in the SC that has the same message reference number and same
106 destination address as an previously submitted SMS from the same originating
110 The value of the reject-duplicate setting.
112 inline TBool CSmsMessageSettings::RejectDuplicate() const
114 return iMsgFlags&ESmsSettingsRejectDuplicate;
118 Sets the value of the reject-duplicate setting.
120 @param aRejectDuplicate
121 The value to set the reject-duplicate setting to.
123 inline void CSmsMessageSettings::SetRejectDuplicate(TBool aRejectDuplicate)
125 iMsgFlags = (iMsgFlags & ~ESmsSettingsRejectDuplicate) | (aRejectDuplicate?ESmsSettingsRejectDuplicate : ESmsSettingsNoFlags);
129 Tests if a status report (TP-SRR in GSM spec 03.40) will be requested from
132 A value of ETrue indicates that a status report will be requested.
135 The value of the Status report flag.
137 inline TBool CSmsMessageSettings::DeliveryReport() const
139 return iMsgFlags&ESmsSettingsDeliveryReport;
143 Sets if a status report (TP-SRR in GSM spec 03.40) will be requested from the
146 A value of ETrue indicates that a status report will be requested.
148 @param aDeliveryReport
149 The value of the status report flag.
151 inline void CSmsMessageSettings::SetDeliveryReport(TBool aDeliveryReport)
153 iMsgFlags = (iMsgFlags & ~ESmsSettingsDeliveryReport) | (aDeliveryReport?ESmsSettingsDeliveryReport : ESmsSettingsNoFlags);
157 Gets the boolean flag that indicates whether a the reply path (Service Centre
158 address) should be included in the SMS-SUBMIT message (TP-RP in GSM spec 03.40).
160 A value of ETrue indicates that the Service Centre address should be included.
161 This flag is only relavent for SMS-SUBMIT messages.
164 The value of the reply path flag.
167 inline TBool CSmsMessageSettings::ReplyPath() const
169 return iMsgFlags&ESmsSettingsReplyPathRequested;
173 Sets the boolean flag that indicates whether a the reply path (Service Centre
174 address) should be included in the SMS-SUBMIT message (TP-RP in GSM spec 03.40).
176 A value of ETrue indicates that the Service Centre address should be included.
177 This flag is only relavent for SMS-SUBMIT messages.
179 @param aReplyPathRequest
180 The value of the reply path flag.
182 inline void CSmsMessageSettings::SetReplyPath(TBool aReplyPathRequest)
184 iMsgFlags = (iMsgFlags & ~ESmsSettingsReplyPathRequested) | (aReplyPathRequest?ESmsSettingsReplyPathRequested : ESmsSettingsNoFlags);
188 Gets the form in which the message should be delivered to the recipient by
191 Note that the form may or may not actually be supported by the service centre,
192 and that the format of the recipient address(es) may need to be different
193 to a normal telephone number if MessageConversion() is set to any other value
194 than ESmsConvPIDNone, ESmsConvFax, ESmsConvPaging or ESmsConvErmes.
197 The value of the message form specifier.
199 inline TSmsPIDConversion CSmsMessageSettings::MessageConversion() const
201 return iMessageConversion;
205 Sets the form in which the message should be delivered to the recipient by the
208 Note that the form may or may not actually be supported by the service centre,
209 and that the format of the recipient address(es) may need to be different
210 to a normal telephone number if MessageConversion() is set to any other value
211 than ESmsConvPIDNone, ESmsConvFax, ESmsConvPaging or ESmsConvErmes.
214 @param aMessageConversion
215 The message form specifier.
217 inline void CSmsMessageSettings::SetMessageConversion(TSmsPIDConversion aMessageConversion)
219 iMessageConversion=aMessageConversion;
223 Gets the default character set used in the SMS message.
225 Text is stored in Unicode on the Symbian OS phone and is converted into the
226 appropriate character set when the message is sent.
229 The default character set for the message.
231 inline TSmsDataCodingScheme::TSmsAlphabet CSmsMessageSettings::CharacterSet() const
237 Sets the default character set used in the SMS message.
239 Text is stored in Unicode on the Symbian OS phone and is converted into the
240 appropriate character set when the message is sent.
243 The value of the default character set for the message.
245 inline void CSmsMessageSettings::SetCharacterSet(TSmsDataCodingScheme::TSmsAlphabet aAlphabet)
251 Sets the format in which the validity period should be sent in a SMS-DELIVER
254 This is field TP-VPF from GSM spec 03.40.
256 @param aValidityPeriodFormat
257 The validity period format.
259 inline void CSmsMessageSettings::SetValidityPeriodFormat(TSmsFirstOctet::TSmsValidityPeriodFormat aValidityPeriodFormat)
261 iValidityPeriodFormat = aValidityPeriodFormat;
265 Gets the format in which the validity period should be sent in a SMS-DELIVER
269 The validity period format.
271 inline const TSmsFirstOctet::TSmsValidityPeriodFormat CSmsMessageSettings::ValidityPeriodFormat() const
273 return iValidityPeriodFormat;
277 Sets the flag which indicates whether the service center timestamp should
278 be used for the date field in the TMsvEntry in message store. If the flag
279 is not set, then the timestamp from the associated CSmsMessage is used.
281 @param aUseServiceCenterTimestamp
282 Flag to indicate whether to use the service center timestamp
284 inline void CSmsMessageSettings::SetUseServiceCenterTimeStampForDate(TBool aUseServiceCenterTimestamp)
286 iMsgFlags = (iMsgFlags & ~ESmsSettingsUseServiceCenterTimeStamp) | (aUseServiceCenterTimestamp ? ESmsSettingsUseServiceCenterTimeStamp : ESmsSettingsNoFlags);
290 Gets the flag which indicates whether the service center timestamp should
291 be used for the date field in the TMsvEntry in message store. If the flag
292 is not set, then the timestamp from the associated CSmsMessage is used.
294 @return Flag which indcates if service center timestamp will be used.
296 inline TBool CSmsMessageSettings::UseServiceCenterTimeStampForDate() const
298 return iMsgFlags & ESmsSettingsUseServiceCenterTimeStamp;
302 Gets whether the editor should quote the received message at the beginning of
306 A value of ETrue if the editor should quote the received message at the beginning
307 of the reply. EFalse if not.
309 inline TBool CSmsSettings::ReplyQuoted() const
311 return iSetFlags&ESmsSettingsReplyQuoted;
315 Sets whether the editor should quote the received message at the beginning of
319 The value to set the reply-quoted flag to.
321 inline void CSmsSettings::SetReplyQuoted(TBool aReplyQuoted)
323 iSetFlags = (iSetFlags & ~ESmsSettingsReplyQuoted) | (aReplyQuoted?ESmsSettingsReplyQuoted : ESmsSettingsNoFlags);
327 Gets the default schedule delivery type of a new message created using the SMS
331 The schedule delivery type.
333 inline TSmsDelivery CSmsSettings::Delivery() const
339 Sets the default schedule delivery type of a new message created using the SMS
343 The schedule delivery type.
345 inline void CSmsSettings::SetDelivery(TSmsDelivery aDelivery)
352 Gets the way in which status reports that are received by the watcher are handled.
354 By default, this is EDoNotWatchForReport. This value is not supported and
355 therefore the value must be changed from the default.
358 How SMS status reports are handled.
360 @see CSmsSettings::TSmsReportHandling
362 inline CSmsSettings::TSmsReportHandling CSmsSettings::StatusReportHandling() const
364 return iStatusReportHandling;
368 Sets the way in which status reports that are received by the watcher are handled.
370 @param aStatusReportHandling
371 The SMS status report handling data.
373 @see CSmsSettings::TSmsReportHandling
375 inline void CSmsSettings::SetStatusReportHandling(CSmsSettings::TSmsReportHandling aStatusReportHandling)
377 iStatusReportHandling = aStatusReportHandling;
381 Gets the way in which special messages that are received by the watcher are
384 By default, this is EDoNotWatchForReport. This value is not supported and
385 therefore the value must be changed from the default.
388 How special messages are handled.
390 @see CSmsSettings::TSmsReportHandling
392 inline CSmsSettings::TSmsReportHandling CSmsSettings::SpecialMessageHandling() const
394 return iSpecialMessageHandling;
398 Sets the way in which special messages that are received by the watcher are
401 @param aSpecialMessageHandling
402 The special messages handling data.
404 @see CSmsSettings::TSmsReportHandling
406 inline void CSmsSettings::SetSpecialMessageHandling(CSmsSettings::TSmsReportHandling aSpecialMessageHandling)
408 iSpecialMessageHandling = aSpecialMessageHandling;
412 Sets whether the Service settings should be used to update the communications
415 If set, this uses the service settings to update the comms db MODEM table's
416 MODEM_MESSAGE_CENTRE_NUMBER, MODEM_MESSAGE_VALIDITY_PERIOD and
417 MODEM_MESSAGE_DELIVERY_REPORT fields. The update is done when the Service
418 settings are stored into the message store using CSmsSettings::StoreL().
420 The default setting is for the comms db not to be updated - TSmsSettingsCommDbAction::ENone.
423 The communications database action.
425 @see CSmsSettings::TSmsSettingsCommDbAction
426 @see CSmsSettings::StoreL
428 inline void CSmsSettings::SetCommDbAction(CSmsSettings::TSmsSettingsCommDbAction aCommDbAction)
430 iCommDbAction = aCommDbAction;
434 Gets the communications database action.
436 For details, see CSmsSettings::SetCommDbAction().
439 The communications database action.
441 @see CSmsSettings::TSmsSettingsCommDbAction
442 @see CSmsSettings::SetCommDbAction
444 inline CSmsSettings::TSmsSettingsCommDbAction CSmsSettings::CommDbAction() const
446 return iCommDbAction;
450 Sets whether the Service's SMS bearer setting should be used to update the
451 communications database.
453 If set, this uses the service setting to update the comm db global table's
454 SMS_BEARER field. The update is done when the Service settings are stored into
455 the message store using CSmsSettings::StoreL().
457 The default setting is for the comms db not to be updated - TSmsSettingsCommDbAction::ENone.
459 @param aSmsBearerAction
460 The SMS bearer action.
462 @see CSmsSettings::TSmsSettingsCommDbAction
463 @see CSmsSettings::StoreL
465 inline void CSmsSettings::SetSmsBearerAction(CSmsSettings::TSmsSettingsCommDbAction aSmsBearerAction)
467 iSmsBearerAction = aSmsBearerAction;
471 Gets the SMS bearer action.
473 For details, see CSmsSettings::SetCommDbAction().
475 @return The SMS bearer action.
477 @see CSmsSettings::TSmsSettingsCommDbAction
478 @see CSmsSettings::SetSmsBearerAction
480 inline CSmsSettings::TSmsSettingsCommDbAction CSmsSettings::SmsBearerAction() const
482 return iSmsBearerAction;
491 inline void CSmsSettings::SetSmsBearer(CSmsSettings::TMobileSmsBearer aSmsBearer)
493 iSmsBearer = aSmsBearer;
502 inline CSmsSettings::TMobileSmsBearer CSmsSettings::SmsBearer() const
508 Sets the folder ID into which received class 2 SMS-DELIVER messages are stored.
511 The folder ID for received class 2 messages.
513 inline void CSmsSettings::SetClass2Folder(TMsvId aId)
519 Gets the folder ID into which received class 2 SMS-DELIVER messages are stored.
522 The class 2 folder ID.
524 inline TMsvId CSmsSettings::Class2Folder() const
526 return iClass2Folder;
530 Sets the maximum length of the message entry description.
532 The default value is given by KSmsDescriptionLength.
534 @param aDescriptionLength
537 @see KSmsDescriptionLength
539 inline void CSmsSettings::SetDescriptionLength(TInt aDescriptionLength)
541 iDescriptionLength = aDescriptionLength;
545 Gets the maximum length of the message entry description.
548 The maximum length of the message entry description.
550 @see KSmsDescriptionLength
552 inline TInt CSmsSettings::DescriptionLength() const
554 return iDescriptionLength;
558 Gets the ID by which to identify the SMS-DELIVER message PDU for this recipient.
561 The log ID for this recipient.
563 inline TLogId CSmsNumber::LogId() const
569 Sets the ID by which to identify the SMS-DELIVER message PDU for this recipient.
572 The log ID for this recipient.
574 inline void CSmsNumber::SetLogId(TLogId aLogId)
580 Tests if a status report (TP-SRR in GSM spec 03.40) for the last segment will be requested from
583 A value of ETrue indicates that a status report will be requested for the last segment.
586 The value of the Status report flag only for the last segment.
589 inline TBool CSmsMessageSettings::LastSegmentDeliveryReport() const
591 return iMsgFlags & ESmsSettingsLastSegmentDeliveryReport;
595 Sets if a status report (TP-SRR in GSM spec 03.40) for the last segment will be requested from the
598 A value of ETrue indicates that a status report will be requested for the last segment.
600 @param aDeliveryReport
601 The value of the status report flagfor the last segment.
604 inline void CSmsMessageSettings::SetLastSegmentDeliveryReport(TBool aDeliveryReport)
606 iMsgFlags = (iMsgFlags & ~ESmsSettingsLastSegmentDeliveryReport) | (aDeliveryReport?ESmsSettingsLastSegmentDeliveryReport : ENoSmsSettingsLastSegmentDeliveryReport);