Msrp/MsrpHeader/inc/CMSRPMessageBase.h
author Petteri Saari <petteri.saari@digia.com>
Thu, 25 Nov 2010 13:59:42 +0200
branchMSRP_FrameWork
changeset 58 cdb720e67852
parent 25 505ad3f0ce5c
permissions -rw-r--r--
This release addresses the following issues: 1. The crash bug fix when receiving file 2. Now the sending is based on MSRP messages, there is no longer file receiving or sending. Client sends data as MSRP was designed. 3. Soma MSRP stack was created so that the client told the correct session-id, Symbian stack generated it by itself. This is not allowed, it was changed so that clients tell the session-id (same as used in SIP INVITE). 4. Unnecessary division of data to chunks removed when there is no need to interrupt sending. The message is sent in as few chunks as possible. 5. Stack can now receive files and chunks with ?unlimited? size. Old stack wrote the incoming data to memory and did not utilize disk space until the end of chunk was reached (large chunks from another client crashed it). 6. Now when writing the incoming data to file, it will take into account the byte-range header values. So, this complies with the RFC4975 requirements that stack must be able to handle chunks that come in any sequence. 7. Some buffering changes to outgoing/incoming data. 8. The outgoing data is now checked that it does not contain the created transaction-id before sending the data. 9. MSRP success reports are now implemented and tested against servers. 10. Progress report system fixed so progress is now visible on client (all the way to 100%). 11. Message Cancel receiving / Cancel sending now corrected and made to work as rfc4975 requires. (termination from sender and error code from receiver when cancelling). 12. Bug correction related to messages received not belonging to any session, old stack implementation did send error response, but after response was written it did give the buffer to client anyway. Now corrected.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
25
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
     1
/*
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
     2
* Copyright (c) 2009-2010 Nokia Corporation and/or its subsidiary(-ies).
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
     3
* All rights reserved.
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
     4
* This component and the accompanying materials are made available
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
     5
* under the terms of "Eclipse Public License v1.0"
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
     6
* which accompanies this distribution, and is available
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
     7
* at the URL "http://www.eclipse.org/legal/epl-v10.html."
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
     8
* Initial Contributors:
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
     9
* Nokia Corporation - initial contribution.
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    10
* Contributors:
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    11
*
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    12
* Description:
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    13
* MSRP Implementation
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    14
*
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    15
*/
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    16
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    17
#ifndef CMSRPMESSAGEBASE_H
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    18
#define CMSRPMESSAGEBASE_H
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    19
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    20
//  INCLUDES
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    21
#include <e32base.h>
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    22
#include <s32strm.h>
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    23
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    24
// FORWARD DECLARATIONS
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    25
class CMSRPFromPathHeader;
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    26
class CMSRPToPathHeader;
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    27
class CMSRPMessageIdHeader;
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    28
class CMSRPByteRangeHeader;
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    29
class CMSRPContentTypeHeader;
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    30
class CMSRPFailureReportHeader;
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    31
class CMSRPSuccessReportHeader;
58
cdb720e67852 This release addresses the following issues:
Petteri Saari <petteri.saari@digia.com>
parents: 25
diff changeset
    32
class CMSRPStatusHeader;
25
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    33
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    34
// CONSTANTS
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    35
const TInt KMaxLengthOfShortMessage = 4096;
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    36
const TInt KLengthOfMSRPSmallBuffer = 2048;
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    37
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    38
// CLASS DECLARATION
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    39
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    40
/**
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    41
*  @publishedAll
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    42
*
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    43
*  Class provides functions for creation and manipulation of MSRP headers
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    44
*
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    45
*  @lib msrpclient.lib
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    46
*/
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    47
class CMSRPMessageBase : public CBase
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    48
    {
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    49
			
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    50
    public:  // Constructors and destructor
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    51
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    52
        /**
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    53
        * Destructor.
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    54
        */
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    55
		IMPORT_C virtual ~CMSRPMessageBase();
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    56
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    57
    public: // New functions
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    58
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    59
		/**
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    60
		* Sets/resets the recipient's To-Path header
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    61
		* @param aTo a To-Path header to be set, the ownership is transferred
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    62
		*/
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    63
		IMPORT_C void SetToPathHeader( CMSRPToPathHeader* aToPath );
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    64
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    65
		/**
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    66
		* Gets the recipient's To-Path header
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    67
		* @return NULL if not present. Ownership is not
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    68
        *         transferred.
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    69
		*/
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    70
		IMPORT_C const CMSRPToPathHeader* ToPathHeader() const;
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    71
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    72
		/**
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    73
		* Sets/resets the From-Path header
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    74
 		* @param aFromPath From-Path header to be set, the ownership is transferred
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    75
		*/
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    76
		IMPORT_C void SetFromPathHeader( CMSRPFromPathHeader* aFromPath );
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    77
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    78
		/**
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    79
		* Returns From-Path header
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    80
		* @return NULL if not present. Ownership is not
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    81
        *         transferred.
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    82
		*/
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    83
		IMPORT_C const CMSRPFromPathHeader* FromPathHeader() const;
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    84
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    85
		/**
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    86
		* Sets/resets the Content-Type header
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    87
 		* @param aContentType ContentType header to be set, the ownership is transferred
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    88
		*/
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    89
		IMPORT_C void SetContentTypeHeader( CMSRPContentTypeHeader* aContentType );
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    90
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    91
		/**
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    92
		* Returns Content-Type header
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    93
		* @return NULL if not present. Ownership is not
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    94
        *         transferred.
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    95
		*/
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    96
		IMPORT_C const CMSRPContentTypeHeader* ContentTypeHeader() const;
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    97
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    98
		/**
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
    99
		* Sets/resets the Failure-Report header
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   100
 		* @param aFailureReport FailureReport header to be set, the ownership is transferred
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   101
		*/
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   102
		IMPORT_C void SetFailureReportHeader( CMSRPFailureReportHeader* aFailureReport );
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   103
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   104
		/**
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   105
		* Returns Failure-Report header
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   106
		* @return NULL if not present. Ownership is not
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   107
        *         transferred.
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   108
		*/
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   109
		IMPORT_C const CMSRPFailureReportHeader* FailureReportHeader() const;
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   110
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   111
		/**
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   112
		* Sets/resets the Success-Report header
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   113
 		* @param aSuccessReport SuccessReport header to be set, the ownership is transferred
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   114
		*/
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   115
		IMPORT_C void SetSuccessReportHeader( CMSRPSuccessReportHeader* aSuccessReport );
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   116
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   117
		/**
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   118
		* Returns Success-Report header
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   119
		* @return NULL if not present. Ownership is not
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   120
        *         transferred.
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   121
		*/
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   122
		IMPORT_C const CMSRPSuccessReportHeader* SuccessReportHeader() const;
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   123
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   124
		/**
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   125
		* Sets/resets the Message-ID header
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   126
 		* @param aMessageId MessageId header to be set, the ownership is transferred
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   127
		*/
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   128
		IMPORT_C void SetMessageIdHeader( CMSRPMessageIdHeader* aMessageId );
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   129
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   130
		/**
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   131
		* Returns Message-ID header
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   132
		* @return NULL if not present. Ownership is not
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   133
        *         transferred.
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   134
		*/
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   135
		IMPORT_C const CMSRPMessageIdHeader* MessageIdHeader() const;
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   136
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   137
		/**
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   138
		* Sets/resets the Byte-Range header
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   139
 		* @param aByteRange ByteRange header to be set, the ownership is transferred
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   140
		*/
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   141
		IMPORT_C void SetByteRangeHeader( CMSRPByteRangeHeader* aByteRange );
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   142
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   143
		/**
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   144
		* Returns Byte-Range header
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   145
		* @return NULL if not present. Ownership is not
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   146
        *         transferred.
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   147
		*/
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   148
		IMPORT_C const CMSRPByteRangeHeader* ByteRangeHeader() const;
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   149
58
cdb720e67852 This release addresses the following issues:
Petteri Saari <petteri.saari@digia.com>
parents: 25
diff changeset
   150
        /**
cdb720e67852 This release addresses the following issues:
Petteri Saari <petteri.saari@digia.com>
parents: 25
diff changeset
   151
        * Sets/resets the Status header
cdb720e67852 This release addresses the following issues:
Petteri Saari <petteri.saari@digia.com>
parents: 25
diff changeset
   152
        * @param aStatus status header to be set, the ownership is transferred
cdb720e67852 This release addresses the following issues:
Petteri Saari <petteri.saari@digia.com>
parents: 25
diff changeset
   153
        */
cdb720e67852 This release addresses the following issues:
Petteri Saari <petteri.saari@digia.com>
parents: 25
diff changeset
   154
        IMPORT_C void SetStatusHeader( CMSRPStatusHeader* aStatus );
cdb720e67852 This release addresses the following issues:
Petteri Saari <petteri.saari@digia.com>
parents: 25
diff changeset
   155
cdb720e67852 This release addresses the following issues:
Petteri Saari <petteri.saari@digia.com>
parents: 25
diff changeset
   156
        /**
cdb720e67852 This release addresses the following issues:
Petteri Saari <petteri.saari@digia.com>
parents: 25
diff changeset
   157
        * returns Status header
cdb720e67852 This release addresses the following issues:
Petteri Saari <petteri.saari@digia.com>
parents: 25
diff changeset
   158
        * @return status header, NULL if not present. Ownership is not
cdb720e67852 This release addresses the following issues:
Petteri Saari <petteri.saari@digia.com>
parents: 25
diff changeset
   159
        *         transferred.
cdb720e67852 This release addresses the following issues:
Petteri Saari <petteri.saari@digia.com>
parents: 25
diff changeset
   160
        */
cdb720e67852 This release addresses the following issues:
Petteri Saari <petteri.saari@digia.com>
parents: 25
diff changeset
   161
        IMPORT_C const CMSRPStatusHeader* StatusHeader( ) const;
cdb720e67852 This release addresses the following issues:
Petteri Saari <petteri.saari@digia.com>
parents: 25
diff changeset
   162
25
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   163
		/**
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   164
		* Writes the object to a RWriteStream
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   165
		* @param aWriteStream a stream where the object is to be externalized
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   166
		*/
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   167
		virtual void ExternalizeL( RWriteStream& aWriteStream ) = 0;
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   168
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   169
    protected:
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   170
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   171
		/**
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   172
        * Constructor.
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   173
        */
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   174
	    CMSRPMessageBase();
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   175
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   176
    protected: // Data
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   177
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   178
		// Headers
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   179
        // For setting and getting MSRP "From-Path" header field
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   180
        CMSRPFromPathHeader* iFromPath;
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   181
        // For setting and getting MSRP "To-Path" header field
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   182
        CMSRPToPathHeader* iToPath;
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   183
        // For setting and getting MSRP "Message-ID" header field
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   184
        CMSRPMessageIdHeader* iMessageId;
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   185
        // For setting and getting MSRP "Byte-Range" header field
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   186
        CMSRPByteRangeHeader* iByteRange;
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   187
        // For setting and getting MSRP "Content-Type" header field
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   188
        CMSRPContentTypeHeader* iContentType;
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   189
        // For setting and getting MSRP "Failure-Report" header field
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   190
        CMSRPFailureReportHeader* iFailureReport;
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   191
        // For setting and getting MSRP "Success-Report" header field
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   192
        CMSRPSuccessReportHeader* iSuccessReport;
58
cdb720e67852 This release addresses the following issues:
Petteri Saari <petteri.saari@digia.com>
parents: 25
diff changeset
   193
        // For setting and getting MSRP "Status" header field
cdb720e67852 This release addresses the following issues:
Petteri Saari <petteri.saari@digia.com>
parents: 25
diff changeset
   194
        CMSRPStatusHeader* iStatusHeader;        
25
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   195
	};
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   196
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   197
#endif // CMSRPMESSAGEBASE_H
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   198
505ad3f0ce5c MSRP Chat and File Sharing FrameWork - Initial Contribution from Nokia.
shivsood
parents:
diff changeset
   199
// End of File