epoc32/include/smut.h
branchSymbian2
changeset 3 e1b950c65cb4
parent 2 2fe1408b6811
child 4 837f303aceeb
     1.1 --- a/epoc32/include/smut.h	Tue Mar 16 16:12:26 2010 +0000
     1.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.3 @@ -1,154 +0,0 @@
     1.4 -// Copyright (c) 1999-2009 Nokia Corporation and/or its subsidiary(-ies).
     1.5 -// All rights reserved.
     1.6 -// This component and the accompanying materials are made available
     1.7 -// 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
     1.8 -// which accompanies this distribution, and is available
     1.9 -// at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
    1.10 -//
    1.11 -// Initial Contributors:
    1.12 -// Nokia Corporation - initial contribution.
    1.13 -//
    1.14 -// Contributors:
    1.15 -//
    1.16 -// Description:
    1.17 -//
    1.18 -
    1.19 -#ifndef __SMUT_H__
    1.20 -#define __SMUT_H__
    1.21 -
    1.22 -#include <msvstd.h>
    1.23 -#include <msvids.h>
    1.24 -#include <barsc.h>
    1.25 -
    1.26 -class CSmsMessage;
    1.27 -class CContactItemField;
    1.28 -class TResourceReader;
    1.29 -class CMsvSession;
    1.30 -class CMsvServerEntry;
    1.31 -class CMsvEntry;
    1.32 -class CSmsSettings;
    1.33 -
    1.34 -/**
    1.35 -The SMS MTM UID.
    1.36 -
    1.37 -Used to identify the MTMs used for handling SMS messages.
    1.38 -
    1.39 -@publishedAll
    1.40 -@released
    1.41 -*/
    1.42 -const TUid KUidMsgTypeSMS			= {0x1000102C};
    1.43 -
    1.44 -/**
    1.45 -The default maximum length used when extracting a description for an SMS message.
    1.46 -
    1.47 -Used as default value of aMaxLength in TSmsUtilities::GetDescription. This
    1.48 -function is used to extract a string to used as a suitable description field in
    1.49 -the message index for a particular SMS message.
    1.50 -
    1.51 -The CSmsSettings provides accessors to get and set the preferred maximum
    1.52 -description length.
    1.53 -
    1.54 -@deprecated
    1.55 -This should not really be used outside of the SMS client MTM. The value provided
    1.56 -by the CSmsSettings class should be used.
    1.57 -
    1.58 -@see	CSmsSettings::GetDescriptionLength
    1.59 -*/
    1.60 -const TInt KSmsDescriptionLength	= 32;
    1.61 -
    1.62 -/**
    1.63 -The default maximum length used when extracting the sender/recipiant details for
    1.64 -an SMS message.
    1.65 -
    1.66 -Used as default value of aMaxLength in TSmsUtilities::GetDetails. This function
    1.67 -is used to extract a string to used as the details field in the message index
    1.68 -for a particular SMS message.
    1.69 -
    1.70 -@deprecated
    1.71 -This should really be used at all.
    1.72 -*/
    1.73 -const TInt KSmsDetailsLength		= 32;
    1.74 -
    1.75 -_LIT(KSmsResourceFile, "\\resource\\messaging\\SMSS.RSC");
    1.76 -
    1.77 -/**
    1.78 -SMS Messaging utility functions.
    1.79 -
    1.80 -@publishedAll
    1.81 -@released
    1.82 -*/
    1.83 -class TSmsUtilities
    1.84 -	{
    1.85 -public:
    1.86 -
    1.87 -/**
    1.88 -Special SMS Message Indication Type.
    1.89 -
    1.90 -A special SMS message indication is used to notify of waiting services, for
    1.91 -instance a voicemail message.
    1.92 -
    1.93 -The TSmsUtilitiesSpecialMessageType enum represents the flags for the known
    1.94 -indication types.
    1.95 -*/
    1.96 -	enum TSmsUtilitiesSpecialMessageType
    1.97 -		{
    1.98 -/**
    1.99 -Voice message waiting.
   1.100 -*/
   1.101 -		EVoiceMessageWaiting = 0,
   1.102 -/**
   1.103 -Fax message waiting.
   1.104 -*/
   1.105 -		EFaxMessageWaiting,
   1.106 -/**
   1.107 -E-mail message waiting.
   1.108 -*/
   1.109 -		EEmailMessageWaiting,
   1.110 -/**
   1.111 -Other message-type waiting (see 3GPP TS 23.038 [9] for definition of "other").
   1.112 -*/
   1.113 -		EOtherMessageWaiting,
   1.114 -/**
   1.115 -Mask used to obtain the mesasge indication type from the SMS data.
   1.116 -*/
   1.117 -		ESpecialMessageTypeMask = 0x7F
   1.118 -		};
   1.119 -
   1.120 -	/**
   1.121 -	@internalComponent
   1.122 -	@removed
   1.123 -	*/
   1.124 -	IMPORT_C void Dummy_Export_1();
   1.125 -	/**
   1.126 -	@internalComponent
   1.127 -	@removed
   1.128 -	*/
   1.129 -	IMPORT_C void Dummy_Export_2();
   1.130 -
   1.131 -	IMPORT_C static void ServiceIdL(CMsvServerEntry& aEntry, TMsvId& aFirstId, TUid aMtm = KUidMsgTypeSMS, CMsvEntrySelection* aServiceIds = NULL);
   1.132 -	IMPORT_C static void ServiceIdL(CMsvEntry& aEntry, TMsvId& aFirstId, TUid aMtm = KUidMsgTypeSMS, CMsvEntrySelection* aServiceIds = NULL);
   1.133 -	IMPORT_C static void ServiceIdL(CMsvSession& aSession, TMsvId& aFirstId, TUid aMtm = KUidMsgTypeSMS, CMsvEntrySelection* aServiceIds = NULL); //more efficient version of the previous one
   1.134 -
   1.135 -	IMPORT_C static void PopulateMsgEntry(TMsvEntry& aEntry, const CSmsMessage& aMessage, TMsvId aServiceId, TUid aMtm = KUidMsgTypeSMS);
   1.136 -	IMPORT_C static void PopulateMsgEntry(TMsvEntry& aEntry, const CSmsMessage& aMessage, TMsvId aServiceId, const CSmsSettings& aSettings, TUid aMtm = KUidMsgTypeSMS);
   1.137 -
   1.138 -	IMPORT_C static TInt GetDetails(RFs& aFs, const CSmsMessage& aMessage, TDes& aDetails, TInt aMaxLength = KSmsDetailsLength);
   1.139 -	IMPORT_C static TInt GetDetails(RFs& aFs, const TDesC& aFromAddress, TDes& aDetails, TInt aMaxLength = KSmsDetailsLength);
   1.140 -	IMPORT_C static TInt GetDescription(const CSmsMessage& aMessage, TDes& aDescription, TInt aMaxLength = KSmsDescriptionLength);
   1.141 -
   1.142 -	IMPORT_C static RResourceFile OpenResourceFileL(RFs& aFs);
   1.143 -	IMPORT_C static void ReadResourceStringL(RResourceFile aResourceFile, TInt aResourceId, TDes& aString);
   1.144 -
   1.145 -private:
   1.146 -	static void CompareEntryL(const TMsvEntry& aEntry, TUid aMtm, TMsvId& aFirstId, CMsvEntrySelection* aServiceIds);
   1.147 -	static void GetName(CContactItemField& aField, TUid aFieldType, TDes& aName);
   1.148 -	static void DoGetDetailsL(RFs& aFs, const TDesC& aFromAddress, TDes& aDetails, TInt aMaxLength);
   1.149 -	static void Replace(const TDesC& aOld, const TDesC& aNew, TDes& aString);
   1.150 -
   1.151 -	static TBool DoGetDescriptionL(const CSmsMessage& aMessage, TDes& aDescription, TInt aMaxLength);
   1.152 -	static void ExtractDescriptionFromMessage(const CSmsMessage& aMessage, TDes& aDescription, TInt aMaxLength);
   1.153 -
   1.154 -	static TBool ValidGsmNumber(const TDesC& aTelephone);
   1.155 -	};
   1.156 -
   1.157 -#endif	// __SMUT_H__