1 // Copyright (c) 1997-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.
22 #if !defined(__ES_WSMS_H__)
27 /** WAP SMS Protocol Module address family ID. */
28 const TUint KWAPSMSAddrFamily=0x011;
29 /** WAP SMS Protocol Module datagram protocol ID. */
30 const TUint KWAPSMSDatagramProtocol=0x01;
31 /** WAP SMS Protocol Module maximum number of sockets supported. */
32 const TInt KWAPSMSNumberSockets=0x100;
33 /** The maximum datagram size the SMS sockets protocol supports. */
34 const TUint KWAPSMSMaxDatagramSize = 255*160; // Based on 7 bit encoding
35 /** WAP SMS Protocol Module service information flags. */
36 const TUint KWAPSMSDatagramServiceInfo = KSIConnectionLess | KSIMessageBased;
37 /** CDMA WAP SMS Protocol Module address family ID for legacy WDP application. */
38 const TUint KWAPCDMASMSAddrFamily=0x013;
43 _LIT(KWAPSMSProtocolId,"WAPSMS Datagram");
44 _LIT(KWAPCDMASMSProtocolId,"WAP CDMA SMS Datagram");
46 //////////////////////////////////////////////////////////////////////////////
47 // Wap Address / Port Settings
48 //////////////////////////////////////////////////////////////////////////////
50 /** WAP port setting. */
54 EWapPortUnspecified = -1,
55 /** Connectionless session protocol. */
57 /** Connection oriented session protocol. */
58 EWapPortWspWtp = 9201,
59 /** Secure connectionless session protocol. */
60 EWapPortWspWtls = 9202,
61 /** Secure connection oriented session protocol. */
62 EWapPortWspWtpWtls = 9203,
66 EWapPortVCardWtls = 9206,
70 EWapPortVCalWtls = 9207
75 * Socket address type used with the WAP SMS Protocol Module.
79 class TWapAddr : public TSockAddr
82 enum { EMaxWapAddressLength = 24 };
85 * Gets the WAP port number.
87 * * @return WAP port number
89 inline TWapPortNumber WapPort() const;
92 * Sets the WAP port number.
94 * * @param aPort WAP port number
96 inline void SetWapPort(TWapPortNumber aPort);
99 * Sets the WAP address.
101 * * @param aTel WAP address
103 inline void SetWapAddress(const TDesC8& aTel);
106 * Gets the WAP address.
108 * * @return WAP address
110 inline TPtrC8 WapAddress() const;
115 * @param aAddr Object to compare
116 * * @return ETrue if the object value's are equal
118 inline TBool operator==(const TWapAddr& aAddr) const;
121 //////////////////////////////////////////////////////////////////////////////
123 //////////////////////////////////////////////////////////////////////////////
125 /** WAP SMS Protocol Module option level, for RSocket::SetOpt() and RSocket::GetOpt() calls. */
126 const TInt KWapSmsOptionLevel = KSOLSocket + 1;
129 * WAP SMS Protocol Module option for the data coding scheme.
131 * * anOption in RSocket::GetOpt() and RSocket::SetOpt() should be a TWapSmsDataCodingScheme value.
133 const TInt KWapSmsOptionNameDCS = 0x01;
136 const TInt KWapSmsOptionSmartMessage = 0x02;
138 /** WAP SMS Protocol Module option to set the message type to WAP datagram. */
139 const TInt KWapSmsOptionWapDatagram = 0x03;
141 /** WAP SMS Protocol Module option to set the status report of the last segment. */
142 const TInt KWapSmsStatusReportScheme = 0x06; // KWapSmsOptionNewStyleClient = 0x04;
143 // KWapSmsOptionOKToDeleteMessage = 0x05;
144 // Defined in wap_sock.h
148 * WAP Data Coding Scheme types.
150 * * These are used with KWapSmsOptionNameDCS.
152 enum TWapSmsDataCodingScheme
161 /** WAP Status Report Scheme types.
163 * These are used with KWapSmsStatusReportScheme. */
164 enum TWapSmsStatusReportScheme
166 /** Default Scheme. */
170 /** Control Information Element Scheme. */
171 EWapSmsCtrlInfoElement
174 #include "es_wsms.inl"