00001 /* 00002 * ============================================================================= 00003 * Name : siprouteheaderbase.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 CSIPROUTEHEADERBASE_H 00023 #define CSIPROUTEHEADERBASE_H 00024 00025 // INCLUDES 00026 #include "SipParameterHeaderBase.h" 00027 #include "_sipcodecdefs.h" 00028 00029 // FORWARD DECLARATIONS 00030 class CSIPAddress; 00031 class CSIPHeaderGenericParams; 00032 00033 // CLASS DECLARATION 00042 class CSIPRouteHeaderBase : public CSIPParameterHeaderBase 00043 { 00044 public: // Constructors and destructor 00045 00049 IMPORT_C virtual ~CSIPRouteHeaderBase(); 00050 00051 00052 public: // New functions 00053 00059 IMPORT_C void SetSIPAddressL(CSIPAddress* aSIPAddress); 00060 00065 IMPORT_C const CSIPAddress& SIPAddress() const; 00066 00071 IMPORT_C CSIPAddress& SIPAddress(); 00072 00073 00074 public: // From CSIPHeaderBase, for internal use 00075 00076 TBool MoreThanOneAllowed() const; 00077 TPreferredPlace PreferredPlaceInMessage() const; 00078 00079 protected: // Contructors 00080 00081 CSIPRouteHeaderBase(); 00082 void ConstructL(); 00083 void ConstructL(CSIPAddress* aSIPAddress); 00084 void ConstructL(const CSIPRouteHeaderBase& aRouteHeaderBase); 00085 00086 protected: // Data 00087 00088 CSIPAddress* iSIPAddress; 00089 CSIPHeaderGenericParams* iParams; 00090 00091 private: // From CSIPParameterHeaderBase 00092 00093 HBufC8* ToTextMandatoryPartLC() const; 00094 void ParseMandatoryPartL(const TDesC8& aMandatoryPart); 00095 const CSIPParamContainerBase& Params() const; 00096 CSIPParamContainerBase& Params(); 00097 00098 private: // For testing purposes 00099 00100 UNIT_TEST(CSIPRouteHeaderBaseTest) 00101 }; 00102 00103 // CSIPROUTEHEADERBASE_H 00104 #endif 00105 00106 // End of File