epoc32/include/sipcallidheader.h
author William Roberts <williamr@symbian.org>
Tue, 16 Mar 2010 16:12:26 +0000
branchSymbian2
changeset 2 2fe1408b6811
parent 0 061f57f2323e
permissions -rw-r--r--
Final list of Symbian^2 public API header files
     1 /*
     2 * Copyright (c) 2004-2009 Nokia Corporation and/or its subsidiary(-ies).
     3 * All rights reserved.
     4 * This component and the accompanying materials are made available
     5 * 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
     6 * which accompanies this distribution, and is available
     7 * at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
     8 *
     9 * Initial Contributors:
    10 * Nokia Corporation - initial contribution.
    11 *
    12 * Contributors:
    13 *
    14 * Description:
    15 * Name          : sipcallidheader.h
    16 * Part of       : SIP Codec
    17 * Version       : SIP/4.0 
    18 *
    19 */
    20 
    21 
    22 
    23 
    24 #ifndef CSIPCALLIDHEADER_H
    25 #define CSIPCALLIDHEADER_H
    26 
    27 //  INCLUDES
    28 #include "sipheaderbase.h"
    29 #include "_sipcodecdefs.h"
    30 
    31 // CLASS DECLARATION
    32 /**
    33 * @publishedAll
    34 * @released
    35 *
    36 * Class for a SIP Call-ID header.
    37 *
    38 * @lib sipcodec.lib
    39 */
    40 class CSIPCallIDHeader : public CSIPHeaderBase
    41 	{
    42 	public:	// Constructors and destructor
    43 
    44 		/**
    45 		* Constructs a CSIPCallIDHeader from textual representation 
    46 		* of the header's value part.
    47 		* @param aValue a value part of a "Call-ID"-header (e.g. "ab2x@zb7y")
    48 		* @returns a new instance of CSIPCallIDHeader
    49 		*/
    50 		IMPORT_C static CSIPCallIDHeader* DecodeL(const TDesC8& aValue);
    51 
    52 		/**
    53 		* Destructor
    54 		*/
    55 		IMPORT_C ~CSIPCallIDHeader ();
    56 
    57 
    58 	public: // New functions
    59 
    60 		/**
    61 		* Compares this instance to another "Call-ID" header object
    62 		* @param aCallIDHeader a header to compare to
    63 		* @returns ETrue if "Call-ID" headers are similar
    64 		*/
    65 		IMPORT_C TBool operator==(const CSIPCallIDHeader& aCallIDHeader);
    66 		
    67 		/**
    68 		* Constructs an instance of a CSIPCallIDHeader from a RReadStream
    69 		* @param aReadStream a stream containing the value of the
    70 		*	     externalized object (header name not included). 
    71 		* @return an instance of a CSIPCallIDHeader
    72 		*/
    73 		IMPORT_C static CSIPHeaderBase* 
    74 			InternalizeValueL(RReadStream& aReadStream);		
    75 
    76 
    77 	public: // From CSIPHeaderBase
    78 
    79 		/**
    80 		* From CSIPHeaderBase CloneL
    81 		*/
    82 		IMPORT_C CSIPHeaderBase* CloneL() const;
    83 		
    84 		/**
    85 		* From CSIPHeaderBase Name
    86 		*/		
    87 		IMPORT_C RStringF Name() const;
    88 
    89 		/**
    90 		* From CSIPHeaderBase ToTextValueL
    91 		*/
    92 		IMPORT_C HBufC8* ToTextValueL() const;
    93 		
    94 
    95 	public: // From CSIPHeaderBase, for internal use
    96         
    97         /**
    98         * @internalComponent
    99         */	
   100 		TBool HasCompactName() const;
   101 
   102         /**
   103         * @internalComponent
   104         */		
   105 		RStringF CompactName() const;
   106 		
   107         /**
   108         * @internalComponent
   109         */		
   110 		TPreferredPlace PreferredPlaceInMessage() const;
   111 
   112 	public: // New functions, for internal use
   113 
   114 		static RPointerArray<CSIPHeaderBase> BaseDecodeL(const TDesC8& aValue);
   115 
   116 	private: // From CSIPHeaderBase
   117 
   118 		void ExternalizeValueL (RWriteStream& aWriteStream) const;
   119 
   120 	private: // Constructors
   121 
   122 		CSIPCallIDHeader();
   123 
   124 	private: // New functions
   125 
   126 		void ParseL(const TDesC8& aValue);
   127 
   128 	private: // Data
   129 
   130 		HBufC8* iCallID;
   131 
   132 	private: // For testing purposes
   133 	
   134 		UNIT_TEST(CSIPCallIDHeaderTest)
   135 	};
   136 
   137 
   138 #endif // end of CSIPCALLIDHEADER_H
   139 
   140 // End of File