epoc32/include/mw/sip_subconparams.h
branchSymbian2
changeset 3 e1b950c65cb4
parent 2 2fe1408b6811
child 4 837f303aceeb
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/epoc32/include/mw/sip_subconparams.h	Wed Mar 31 12:27:01 2010 +0100
     1.3 @@ -0,0 +1,278 @@
     1.4 +// Copyright (c) 2005-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 +// SIPSCPR_subconparams.h
    1.18 +// SIP extension parameters definition
    1.19 +// 
    1.20 +//
    1.21 +
    1.22 +
    1.23 +
    1.24 +/**
    1.25 + @file
    1.26 + @publishedAll
    1.27 + @released since v9.2
    1.28 +*/
    1.29 +
    1.30 +#ifndef SIP_SUBCONPARAMS_H
    1.31 +#define SIP_SUBCONPARAMS_H
    1.32 +
    1.33 +#include <es_sock.h>
    1.34 +#include <comms-infras/metabuffer.h>
    1.35 +
    1.36 +/** The numeric value of ECOM plugin identifier for this SubConnection parameter extension.See the assisting *.rss file. */
    1.37 +const TInt KSubConSIPParametersUid = 0x10274C18;
    1.38 +
    1.39 +/** The numeric value of Invite identifier for SIP extension parameter set  */
    1.40 +const TInt KSubConSIPInviteParamsType = 1;
    1.41 +
    1.42 +/** The numeric value of Subscribe identifier for SIP extension parameter set  */
    1.43 +const TInt KSubConSIPSubscribeParamsType = 2;
    1.44 +
    1.45 +/** The numeric value of Authentication of SIP extension parameter set  */
    1.46 +const TInt KSubConSIPAuthenticateParamsType = 3;
    1.47 +
    1.48 +class CSubConSIPInviteParamSet : public CSubConExtensionParameterSet
    1.49 +/** 
    1.50 +This contains the SIP Invite parameters that will be passed via subconnection
    1.51 +to the SIP stack
    1.52 +@publishedAll
    1.53 +@released since v9.2 
    1.54 +*/
    1.55 +{
    1.56 +public:
    1.57 +     /**
    1.58 +	 Creates a new SubConSIPInvite parameter set object.  
    1.59 +	 @param     aFamily ,contains family related info 
    1.60 +	 @param		aType contains parameter Type such as (Requested, Acceptable and Granted)
    1.61 +	 @return    A pointer to the newly allocated object.
    1.62 +	 @leave 	KErrArgument if the data is not of type TParameterSetType.
    1.63 +	 */   
    1.64 +	inline static CSubConSIPInviteParamSet* NewL(CSubConParameterFamily& aFamily, CSubConParameterFamily::TParameterSetType aType);
    1.65 +	inline static CSubConSIPInviteParamSet* NewL();
    1.66 +	
    1.67 +	/** Constructor. */
    1.68 +	inline CSubConSIPInviteParamSet();
    1.69 +	/** Destructor. */
    1.70 +	virtual ~CSubConSIPInviteParamSet();
    1.71 +	
    1.72 +	/** Getters for SIP header. */
    1.73 +	/** Gets Request URI field of the SIP header. **/
    1.74 +	inline const TPtrC8 GetRequestUri() const;
    1.75 +	/** Gets From field of the SIP header. **/	
    1.76 +	inline const TPtrC8 GetFrom() const;
    1.77 +	/** Gets To field of the SIP header. **/	
    1.78 +	inline const TPtrC8 GetTo() const;
    1.79 +	/** Gets Contact field of the SIP header. **/	
    1.80 +	inline const TPtrC8 GetContact() const;
    1.81 +	/** Gets ContentType field of the SIP header. **/	
    1.82 +	inline const TPtrC8 GetContentType() const;
    1.83 +	/** Gets ContentSubType field of the SIP header. **/	
    1.84 +	inline const TPtrC8 GetContentSubType() const;
    1.85 +	/** Gets Content field of the SIP header. **/
    1.86 +	inline const TPtrC8 GetContent() const;
    1.87 +	
    1.88 +	/** Setters for SIP header. 
    1.89 +	/** Sets Request URI field of the SIP header. **/
    1.90 +	inline void   SetRequestUriL(const TPtrC8 & aReqUri);
    1.91 +	/** Sets From field of the SIP header. **/	
    1.92 +	inline void   SetFromL(const TPtrC8 & aFrom);
    1.93 +	/** Sets To field of the SIP header. **/	
    1.94 +	inline void   SetToL(const TPtrC8 & aTo);
    1.95 +	/** Sets Contact field of the SIP header. **/	
    1.96 +	inline void   SetContactL(const TPtrC8 & aContact);
    1.97 +	/** Sets Content Type field of the SIP header. **/		
    1.98 +	inline void   SetContentTypeL(const TPtrC8 & aContentType);
    1.99 +	/** Sets Content Sub Type field of the SIP header. **/	
   1.100 +	inline void   SetContentSubTypeL(const TPtrC8 & aContentSubType);
   1.101 +	/** Sets Content field of the SIP header. **/		
   1.102 +	inline void	  SetContentL(const TPtrC8 & aContent);
   1.103 +	
   1.104 +	DATA_VTABLE
   1.105 +protected:
   1.106 +
   1.107 +	/** The Request URI field of the SIP header. */
   1.108 +	RBuf8	iReqUri;
   1.109 +	/** The From field of the SIP header. */
   1.110 +	RBuf8	iFrom;
   1.111 +	/** The To field of the SIP header. */
   1.112 +	RBuf8	iTo;
   1.113 +	/** The Contact field of the SIP header. */
   1.114 +	RBuf8	iContact;
   1.115 +	/** The Content Type field of the SIP header. */
   1.116 +	RBuf8	iContentType;
   1.117 +	/** The Content Sub Type field of the SIP header. */
   1.118 +	RBuf8	iContentSubType;
   1.119 +	/** The Content field of the SIP header. */
   1.120 +	RBuf8	iContent;
   1.121 +	};
   1.122 +	
   1.123 +	
   1.124 +	
   1.125 +class CSubConSIPSubscribeParamSet : public CSubConExtensionParameterSet
   1.126 +/** 
   1.127 +This contains the SIP Subscribe parameters that will be passed via subconnection
   1.128 +to the SIP stack
   1.129 +@publishedAll
   1.130 +@released since v9.2 
   1.131 +*/
   1.132 +{
   1.133 +public:
   1.134 +    /**
   1.135 +	 Creates a new SubConSIPSubscribe parameter set object.  
   1.136 +	 @param     aFamily ,contains family related info 
   1.137 +	 @param		aType contains parameter Type such as (Requested, Acceptable and Granted)
   1.138 +	 @return    A pointer to the newly allocated object.
   1.139 +	 @leave 	KErrArgument if the data is not of type TParameterSetType.
   1.140 +	 */    
   1.141 +	inline static CSubConSIPSubscribeParamSet* NewL(CSubConParameterFamily& aFamily, CSubConParameterFamily::TParameterSetType aType);
   1.142 +	inline static CSubConSIPSubscribeParamSet* NewL();
   1.143 +	
   1.144 +	/** Constructor. */
   1.145 +	inline CSubConSIPSubscribeParamSet();
   1.146 +	
   1.147 +	/** Destructor. */
   1.148 +    virtual ~CSubConSIPSubscribeParamSet();
   1.149 +    
   1.150 +	/** Getters for SIP header. */
   1.151 +	/** Gets Request URI field of the SIP header. **/
   1.152 +	inline const TPtrC8 GetRequestUri() const;	
   1.153 +	/** Gets From field of the SIP header. **/
   1.154 +	inline const TPtrC8 GetFrom() const;
   1.155 +	/** Gets To field of the SIP header. **/	
   1.156 +	inline const TPtrC8 GetTo() const;
   1.157 +	/** Gets Contact field of the SIP header. **/
   1.158 +	inline const TPtrC8 GetContact() const;
   1.159 +	/** Gets Event Type field of the SIP header. **/
   1.160 +	inline const TPtrC8 GetEventType() const;
   1.161 +	/** Gets Accept Type field of the SIP header. **/
   1.162 +	inline const TPtrC8 GetAcceptType() const;
   1.163 +	/** Gets Accept Sub Type field of the SIP header. **/
   1.164 +	inline const TPtrC8 GetAcceptSubType() const;
   1.165 +	/** Gets Expires field of the SIP header. **/
   1.166 +	inline const TInt   GetExpires() const;
   1.167 +	/** Gets Auto Refresh field of the SIP header. **/
   1.168 +	inline const TBool  GetAutoRefresh() const;
   1.169 +	
   1.170 +	/** Setters for SIP header. */
   1.171 +	/** Sets Request URI field of the SIP header. **/
   1.172 +	inline void  SetRequestUriL(const TPtrC8 & aReqUri);
   1.173 +	/** Sets From field of the SIP header. **/	
   1.174 +	inline void  SetFromL(const TPtrC8 & aFrom);
   1.175 +	/** Sets To field of the SIP header. **/	
   1.176 +	inline void  SetToL(const TPtrC8 & aTo);
   1.177 +	/** Sets Contact field of the SIP header. **/
   1.178 +	inline void  SetContactL(const TPtrC8 & aContact);
   1.179 +	/** Sets Event Type field of the SIP header. **/
   1.180 +	inline void  SetEventTypeL(const TPtrC8 & aEventType);
   1.181 +	/** Sets Accept Type field of the SIP header. **/
   1.182 +	inline void  SetAcceptTypeL(const TPtrC8 & aAcceptType);
   1.183 +	/** Sets Accept Sub Type field of the SIP header. **/
   1.184 +	inline void  SetAcceptSubTypeL(const TPtrC8 & aAcceptSubType);
   1.185 +	/** Sets Expires Sub Type field of the SIP header. **/
   1.186 +	inline void  SetExpires(TInt aExpires);
   1.187 +	/** Sets AutoRfresh field of the SIP header. **/
   1.188 +	inline void  SetAutoRefresh(TBool aAutoRefresh);
   1.189 +	
   1.190 +	
   1.191 +	DATA_VTABLE
   1.192 +protected:
   1.193 +	
   1.194 +	/** The Request URI field of the SIP header. */
   1.195 +	RBuf8	iReqUri;
   1.196 +	/** The From field of the SIP header. */
   1.197 +	RBuf8	iFrom;
   1.198 +	/** The To field of the SIP header. */
   1.199 +	RBuf8	iTo;
   1.200 +	/** The Contact field of the SIP header. */
   1.201 +	RBuf8	iContact;
   1.202 +	/** The Event Type field of the SIP header. */
   1.203 +	RBuf8	iEventType;
   1.204 +	/** The Accept Type field of the SIP header. */
   1.205 +	RBuf8	iAcceptType;
   1.206 +	/** The Accept Sub Type field of the SIP header. */
   1.207 +	RBuf8	iAcceptSubType;
   1.208 +	/** The Expires field of the SIP header. */
   1.209 +	TInt	iExpires;
   1.210 +	/** The AutoRefresh field of the SIP header. */
   1.211 +	TBool   iAutoRefresh;
   1.212 +};
   1.213 +	
   1.214 +class CSubConSIPAuthenticateParamSet : public CSubConExtensionParameterSet
   1.215 +/** 
   1.216 +This contains the SIP Authenticate parameters that will be passed via subconnection
   1.217 +to the SIP stack
   1.218 +@publishedAll
   1.219 +@released since v9.2 
   1.220 +*/
   1.221 +{
   1.222 +public:
   1.223 +    /**
   1.224 +	 Creates a new SubConSIPAuthenticate parameter set object.  
   1.225 +	 @param     aFamily ,contains family related info 
   1.226 +	 @param		aType contains parameter Type such as (Requested, Acceptable and Granted)
   1.227 +	 @return    A pointer to the newly allocated object.
   1.228 +	 @leave 	KErrArgument if the data is not of type TParameterSetType.
   1.229 +	 */    
   1.230 +	inline static CSubConSIPAuthenticateParamSet* NewL(CSubConParameterFamily& aFamily, CSubConParameterFamily::TParameterSetType aType);
   1.231 +	inline static CSubConSIPAuthenticateParamSet* NewL();
   1.232 +	
   1.233 +	/** Constructor. */
   1.234 +	inline CSubConSIPAuthenticateParamSet();
   1.235 +	
   1.236 +	/** Destructor. */
   1.237 +	virtual ~CSubConSIPAuthenticateParamSet();
   1.238 +	
   1.239 +	/** Getters for SIP header. */
   1.240 +	/** Gets Username field of the SIP header. **/
   1.241 +	inline const TPtrC8 GetUserName() const;
   1.242 +	/** Gets Password field of the SIP header. **/	
   1.243 +	inline const TPtrC8 GetPassword() const;
   1.244 +	/** Gets Realm field of the SIP header. **/		
   1.245 +	inline const TPtrC8 GetRealm() const;
   1.246 +	
   1.247 +	/** Setters for SIP header. */
   1.248 +	/** Sets Username field of the SIP header. **/
   1.249 +	inline void  SetUserNameL(const TPtrC8 & aUserName);
   1.250 +	/** Sets Password field of the SIP header. **/	
   1.251 +	inline void  SetPasswordL(const TPtrC8 & aPassword);
   1.252 +	/** Sets Realm field of the SIP header. **/	
   1.253 +	inline void  SetRealmL(const TPtrC8 & aRealm);
   1.254 +	
   1.255 +	DATA_VTABLE
   1.256 +protected:
   1.257 +
   1.258 +	/** The Username entry of Authenticate field in a SIP header. */
   1.259 +	RBuf8	iUserName;
   1.260 +	/** The Password entry of Authenticate field in a SIP header. */
   1.261 +	RBuf8	iPassword;
   1.262 +	/** The Realm entry of Authenticate field in a SIP header. */
   1.263 +	RBuf8	iRealm;	
   1.264 +};
   1.265 +
   1.266 +
   1.267 +
   1.268 +class CSIPSubConnExtensionParamsFactory : public CBase
   1.269 +/** Factory used to create instances of the SIP SubConnection Parameter Extension Sets.
   1.270 +
   1.271 +@publishedAll
   1.272 +@released since v9.2 
   1.273 +*/
   1.274 +	{
   1.275 +public:
   1.276 +	static CSubConExtensionParameterSet* NewL(TAny* aConstructionParameters);
   1.277 +	};
   1.278 +
   1.279 +#include <sip_subconparams.inl>
   1.280 +
   1.281 +#endif // SIP_SUBCONPARAMS_H