epoc32/include/sipclienttransaction.h
branchSymbian2
changeset 3 e1b950c65cb4
parent 2 2fe1408b6811
child 4 837f303aceeb
     1.1 --- a/epoc32/include/sipclienttransaction.h	Tue Mar 16 16:12:26 2010 +0000
     1.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.3 @@ -1,173 +0,0 @@
     1.4 -/*
     1.5 -* Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
     1.6 -* All rights reserved.
     1.7 -* This component and the accompanying materials are made available
     1.8 -* 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.9 -* which accompanies this distribution, and is available
    1.10 -* at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
    1.11 -*
    1.12 -* Initial Contributors:
    1.13 -* Nokia Corporation - initial contribution.
    1.14 -*
    1.15 -* Contributors:
    1.16 -*
    1.17 -* Description:
    1.18 -* Name        : sipclienttransaction.h
    1.19 -* Part of     : SIP Client
    1.20 -* Interface   :
    1.21 -* Version     : 1.0
    1.22 -*
    1.23 -*/
    1.24 -
    1.25 -
    1.26 -
    1.27 -
    1.28 -#ifndef CSIPCLIENTTRANSACTION_H
    1.29 -#define CSIPCLIENTTRANSACTION_H
    1.30 -
    1.31 -// INCLUDES
    1.32 -#include "siptransactionbase.h"
    1.33 -
    1.34 -// FORWARD DECLARATIONS
    1.35 -class CSIPRefresh;
    1.36 -
    1.37 -// CLASS DECLARATION
    1.38 -
    1.39 -/**
    1.40 -*  @publishedAll
    1.41 -*  @released
    1.42 -*
    1.43 -*  Class for managing SIP client transactions.
    1.44 -*  It provides services for ending and getting the SIP client transaction
    1.45 -*  parameters. Some client transactions can also be canceled.
    1.46 -*
    1.47 -*  The user of the class cannot instante this class.
    1.48 -*  @lib sipclient
    1.49 -*/
    1.50 -class CSIPClientTransaction: public CSIPTransactionBase
    1.51 -	{
    1.52 -	public: // Destructor
    1.53 -
    1.54 -        /**
    1.55 -        * Destructor
    1.56 -		*/
    1.57 -		IMPORT_C ~CSIPClientTransaction();
    1.58 -
    1.59 -	public: // New functions
    1.60 -
    1.61 -        /**
    1.62 -        * Gets response elements of the most recent response.
    1.63 -        * @return Response elements. Ownership isn't transferred.
    1.64 -        */
    1.65 -		IMPORT_C const CSIPResponseElements* ResponseElements() const;
    1.66 -
    1.67 -        /**
    1.68 -		* Cancels client transaction i.e. creates a CANCEL request and sends it
    1.69 -		* to the remote UA.		
    1.70 -		* @pre State()==EProceeding
    1.71 -		* @pre CancelAllowed()==ETrue
    1.72 -		* @pre Connection().State()==EActive
    1.73 -		* @return SIP CANCEL transaction, ownership is transferred.		
    1.74 -		* @leave KErrSIPInvalidTransactionState if canceling is not possible
    1.75 -		*	at all, or because the transaction is not in a proper state or the
    1.76 -        *   transaction is not related to a dialog.
    1.77 -		* @leave KErrSIPResourceNotAvailable if a required SIP Client API
    1.78 -		*	object has been deleted
    1.79 -		* @capability NetworkServices
    1.80 -		*/
    1.81 -		IMPORT_C CSIPClientTransaction* CancelL();
    1.82 -
    1.83 -		/**
    1.84 -		* Gets the associated refresh with the transaction.
    1.85 -		* If the refresh is associated with the transaction,
    1.86 -		* transaction will be refreshed at defined interval.
    1.87 -		* @return associated refresh or 0-pointer if there's no
    1.88 -		*         associated refresh. Ownership isn't transferred.
    1.89 -		*/
    1.90 -		IMPORT_C const CSIPRefresh* Refresh() const;
    1.91 -
    1.92 -        /**
    1.93 -		* Checks if the client transaction is such that it can be cancelled.
    1.94 -        * This does no check whether the transaction is currently in such a
    1.95 -        * state that the canceling can be done now.
    1.96 -        *
    1.97 -		* @return ETrue if client transaction can be cancelled;
    1.98 -		*         EFalse otherwise
    1.99 -		*/
   1.100 -		IMPORT_C virtual TBool CancelAllowed() const;
   1.101 -
   1.102 -	public: // Constructors, for internal use
   1.103 -
   1.104 -        /**
   1.105 -		* Instantiates a CSIPClientTransaction object, leaves on failure.
   1.106 -        *
   1.107 -        * @param aType Identifies the transaction type        
   1.108 -        * @param aAssociation Object to which the transaction is associated
   1.109 -        *   with.
   1.110 -        * @param aRefresh If transaction is refreshed, this points to a
   1.111 -        *   CSIPRefresh, otherwise this is NULL. Ownership is not transferred.
   1.112 -		* @return SIP client transaction, ownership is transferred.
   1.113 -		*/
   1.114 -		static CSIPClientTransaction*
   1.115 -            NewL(RStringF aType,
   1.116 -                 MTransactionAssociation& aAssociation,
   1.117 -                 CSIPRefresh* aRefresh=0);
   1.118 -
   1.119 -        /**
   1.120 -		* Instantiates a CSIPClientTransaction object and pushes it into
   1.121 -        * CleanupStack, leaves on failure.
   1.122 -        *
   1.123 -        * @param aType Identifies the transaction type        
   1.124 -        * @param aAssociation Object to which the transaction is associated
   1.125 -        *   with.
   1.126 -        * @param aRefresh If transaction is refreshed, this points to a
   1.127 -        *   CSIPRefresh, otherwise this is NULL. Ownership is not transferred.
   1.128 -		* @return SIP client transaction, ownership is transferred.
   1.129 -		*/
   1.130 -		static CSIPClientTransaction*
   1.131 -            NewLC(RStringF aType,
   1.132 -                  MTransactionAssociation& aAssociation,
   1.133 -                  CSIPRefresh* aRefresh=0);
   1.134 -
   1.135 -	public: // New functions, for internal use
   1.136 -
   1.137 -        /**
   1.138 -		* Sets the RequestId.
   1.139 -        *
   1.140 -        * @pre iRequestId == 0
   1.141 -        * @pre aRequestId != 0
   1.142 -		* @param aRequestId RequestId obtained from SIP client
   1.143 -		*/
   1.144 -		void SetRequestId(TUint32 aRequestId);
   1.145 -
   1.146 -        /**
   1.147 -		* Gets the associated refresh with the transaction and allows
   1.148 -        * modification fo the refresh. This method is for internal use only.
   1.149 -        *
   1.150 -		* @return associated refresh or 0-pointer if there's no
   1.151 -		*         associated refresh. Ownership isn't transferred.
   1.152 -		*/
   1.153 -        CSIPRefresh* Refresh();
   1.154 -
   1.155 -        /**
   1.156 -	    * Clears the association from ClientTransaction to CSIPRefresh
   1.157 -	    */
   1.158 -        void RemoveRefresh();	
   1.159 -
   1.160 -    protected: // Constructor
   1.161 -
   1.162 -		CSIPClientTransaction(MTransactionAssociation& aAssociation,
   1.163 -                              CSIPRefresh* aRefresh);
   1.164 -
   1.165 -    private: // Data
   1.166 -
   1.167 -        //Points to the refresh object if this transaction is refreshed.
   1.168 -        //NULL if not refreshed. Not owned.
   1.169 -        CSIPRefresh* iRefresh;
   1.170 -
   1.171 -	private: // For testing purposes
   1.172 -
   1.173 -	    UNIT_TEST(CSIP_Test)
   1.174 -	};
   1.175 -
   1.176 -#endif