2 * Copyright (c) 2004-2009 Nokia Corporation and/or its subsidiary(-ies).
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".
9 * Initial Contributors:
10 * Nokia Corporation - initial contribution.
15 * Name : sipsecurityclientheader.h
17 * Interface : SDK API, SIP Codec API
25 #ifndef CSIPSECURITYCLIENTHEADER_H
26 #define CSIPSECURITYCLIENTHEADER_H
29 #include "sipsecurityheaderbase.h"
30 #include "_sipcodecdefs.h"
37 * Class provides functions for setting and getting SIP "Security-Client"
42 class CSIPSecurityClientHeader : public CSIPSecurityHeaderBase
44 public: // Constructors and destructor
47 * Constructs a CSIPSecurityClientHeader from textual representation
48 * of the header's value part.
49 * @param aValue a value part of a "Security-Client"-header
50 * @return an array containing 1..n instances of CSIPSecurityClientHeader
52 IMPORT_C static RPointerArray<CSIPSecurityClientHeader>
53 DecodeL(const TDesC8& aValue);
56 * Creates a new instance of CSIPSecurityClientHeader
57 * @param aMechanism a Mechanism-Name parameter
58 * in the "Security-Client" header
59 * @return a new instance of CSIPSecurityClientHeader
61 IMPORT_C static CSIPSecurityClientHeader*
62 NewL(const TDesC8& aMechanism);
65 * Creates a new instance of CSIPSecurityClientHeader
66 * and puts it to CleanupStack
67 * @param aMechanism a Mechanism-Name parameter
68 * in the "Security-Client" header
69 * @return a new instance of CSIPSecurityClientHeader
71 IMPORT_C static CSIPSecurityClientHeader*
72 NewLC(const TDesC8& aMechanism);
75 * Destructor, deletes the resources of CSIPSecurityClientHeader.
77 IMPORT_C ~CSIPSecurityClientHeader();
80 public: // New functions
83 * Constructs an instance of a CSIPSecurityClientHeader
85 * @param aReadStream a stream containing the value of the
86 * externalized object (header name not included).
87 * @return an instance of a CSIPSecurityClientHeader
90 IMPORT_C static CSIPHeaderBase*
91 InternalizeValueL(RReadStream& aReadStream);
94 public: // From CSIPHeaderBase
97 * From CSIPHeaderBase CloneL
99 IMPORT_C CSIPHeaderBase* CloneL() const;
102 * From CSIPHeaderBase Name
104 IMPORT_C RStringF Name() const;
107 public: // New functions, for internal use
109 static RPointerArray<CSIPHeaderBase> BaseDecodeL(const TDesC8& aValue);
111 private: // New functions
113 CSIPSecurityClientHeader() ;
115 private: // For testing purposes
117 UNIT_TEST(CSIPSecurityHeaderBaseTest)
120 #endif // CSIPSECURITYCLIENTHEADER_H