S60 3rd Edition API Reference: sipextensionheader.h Source File

sipextensionheader.h

Go to the documentation of this file.
00001 /*
00002 * =============================================================================
00003 *  Name        : sipextensionheader.h
00004 *  Part of     : SIP Codec
00005 *  Interface   : SDK API, SIP Codec API
00006 *  Description : 
00007 *  Version     : SIP/4.0 
00008 *
00009 *  Copyright (c) 2004 Nokia Corporation. 
00010 *  This material, including documentation and any related 
00011 *  computer programs, is protected by copyright controlled by 
00012 *  Nokia Corporation. All rights are reserved. Copying, 
00013 *  including reproducing, storing, adapting or translating, any 
00014 *  or all of this material requires the prior written consent of 
00015 *  Nokia Corporation. This material also contains confidential 
00016 *  information which may not be disclosed to others without the 
00017 *  prior written consent of Nokia Corporation. 
00018 * =============================================================================
00019 */
00020 
00021 
00022 #ifndef CSIPEXTENSIONHEADER_H
00023 #define CSIPEXTENSIONHEADER_H
00024 
00025 //  INCLUDES
00026 #include "sipheaderbase.h"
00027 #include "_sipcodecdefs.h"
00028 
00029 
00030 // CLASS DECLARATION
00041 class CSIPExtensionHeader : public CSIPHeaderBase
00042         {
00043         public: // Constructors and destructor
00044 
00051                 IMPORT_C static CSIPExtensionHeader* 
00052                         NewL(const TDesC8& aName, const TDesC8& aValue);
00053 
00061                 IMPORT_C static CSIPExtensionHeader* 
00062                         NewLC(const TDesC8& aName, const TDesC8& aValue);
00063 
00067                 IMPORT_C ~CSIPExtensionHeader();
00068 
00069 
00070         public: // New functions
00071 
00076                 IMPORT_C void SetValueL(const TDesC8& aValue);
00077 
00082                 IMPORT_C const TDesC8& Value() const;
00083 
00091                 IMPORT_C static CSIPExtensionHeader* 
00092                         InternalizeValueL(RReadStream& aReadStream);
00093 
00094 
00095         public: // From CSIPHeaderBase
00096 
00100                 IMPORT_C CSIPHeaderBase* CloneL() const;
00101 
00105                 IMPORT_C RStringF Name() const;
00106 
00110                 IMPORT_C HBufC8* ToTextValueL() const;
00111 
00115                 IMPORT_C TBool ExternalizeSupported() const;
00116 
00117 
00118         public: // New functions, for internal use
00119 
00120                 void SetNameL(const TDesC8& aName);
00121 
00122         public: // From CSIPHeaderBase, for internal use
00123         
00124                 TBool IsExtensionHeader() const;
00125                 TBool EncodeMultipleToOneLine() const;
00126                 TBool MoreThanOneAllowed() const;
00127                 TBool HasCompactName() const;
00128                 RStringF CompactName() const;
00129                 TPreferredPlace PreferredPlaceInMessage() const;
00130 
00131         private: // From CSIPHeaderBase
00132 
00133                 void ExternalizeValueL(RWriteStream& aWriteStream) const;
00134 
00135         private: // Constructors
00136 
00137                 CSIPExtensionHeader();
00138                 void ConstructL(const TDesC8& aName, const TDesC8& aValue);
00139                 void ConstructL(const CSIPExtensionHeader& aExtensionHeader);
00140                 void DoInternalizeValueL(RReadStream& aReadStream);
00141 
00142         private: // New functions
00143 
00144                 TBool CheckValue (const TDesC8& aValue);
00145         
00146         private: // Data
00147 
00148                 // data
00149                 RStringF iName;
00150                 HBufC8* iValue;
00151 
00152         private: // For testing purposes
00153         
00154                 UNIT_TEST(CSIPExtensionHeaderTest)
00155                 UNIT_TEST(CSIPHeaderLookupTest)
00156         };
00157 
00158 // CSIPEXTENSIONHEADER_H
00159 #endif
00160 
00161 // End of File

Copyright © Nokia Corporation 2001-2007
Back to top