1 sipsupportedheader.h |
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 : sipsupportedheader.h |
|
16 * Part of : SIP Codec |
|
17 * Interface : SDK API, SIP Codec API |
|
18 * Version : SIP/4.0 |
|
19 * |
|
20 */ |
|
21 |
|
22 |
|
23 |
|
24 |
|
25 #ifndef CSIPSUPPORTEDHEADER_H |
|
26 #define CSIPSUPPORTEDHEADER_H |
|
27 |
|
28 // INCLUDES |
|
29 #include "siptokenheaderbase.h" |
|
30 #include "_sipcodecdefs.h" |
|
31 |
|
32 // CLASS DECLARATION |
|
33 /** |
|
34 * @publishedAll |
|
35 * @released |
|
36 * |
|
37 * Class provides functions for setting and getting SIP "Supported" header. |
|
38 * |
|
39 * @lib sipcodec.lib |
|
40 */ |
|
41 class CSIPSupportedHeader : public CSIPTokenHeaderBase |
|
42 { |
|
43 public: // Constructors and destructor |
|
44 |
|
45 /** |
|
46 * Constructs a CSIPSupportedHeader from textual representation |
|
47 * of the header's value part. |
|
48 * @param aValue a value part of a "Supported"-header |
|
49 * @return an array containing 1..n instances of CSIPSupportedHeader |
|
50 */ |
|
51 IMPORT_C static RPointerArray<CSIPSupportedHeader> |
|
52 DecodeL(const TDesC8& aValue); |
|
53 |
|
54 /** |
|
55 * Creates a new instance of CSIPSupportedHeader |
|
56 * @param aValue a tag value |
|
57 * @return a new instance of CSIPSupportedHeader |
|
58 */ |
|
59 IMPORT_C static CSIPSupportedHeader* NewL(RStringF aValue); |
|
60 |
|
61 /** |
|
62 * Creates a new instance of CSIPSupportedHeader |
|
63 * and puts it to CleanupStack |
|
64 * @param aValue a tag value |
|
65 * @return a new instance of CSIPSupportedHeader |
|
66 */ |
|
67 IMPORT_C static CSIPSupportedHeader* NewLC(RStringF aValue); |
|
68 |
|
69 /** |
|
70 * Destructor, deletes the resources of CSIPSupportedHeader. |
|
71 */ |
|
72 IMPORT_C ~CSIPSupportedHeader(); |
|
73 |
|
74 |
|
75 public: // New functions |
|
76 |
|
77 /** |
|
78 * Constructs an instance of a CSIPSupportedHeader from a RReadStream |
|
79 * @param aReadStream a stream containing the value of the |
|
80 * externalized object (header name not included). |
|
81 * @return an instance of a CSIPSupportedHeader |
|
82 */ |
|
83 IMPORT_C static CSIPHeaderBase* |
|
84 InternalizeValueL(RReadStream& aReadStream); |
|
85 |
|
86 |
|
87 public: // From CSIPHeaderBase |
|
88 |
|
89 /** |
|
90 * From CSIPHeaderBase CloneL |
|
91 */ |
|
92 IMPORT_C CSIPHeaderBase* CloneL() const; |
|
93 |
|
94 /** |
|
95 * From CSIPHeaderBase Name |
|
96 */ |
|
97 IMPORT_C RStringF Name() const; |
|
98 |
|
99 |
|
100 public: // From CSIPHeaderBase, for internal use |
|
101 |
|
102 /** |
|
103 * @internalComponent |
|
104 */ |
|
105 TBool HasCompactName() const; |
|
106 |
|
107 /** |
|
108 * @internalComponent |
|
109 */ |
|
110 RStringF CompactName() const; |
|
111 |
|
112 /** |
|
113 * @internalComponent |
|
114 */ |
|
115 TPreferredPlace PreferredPlaceInMessage() const; |
|
116 |
|
117 public: // New functions, for internal use |
|
118 |
|
119 static RPointerArray<CSIPHeaderBase> BaseDecodeL(const TDesC8& aValue); |
|
120 |
|
121 private: // New functions |
|
122 |
|
123 CSIPSupportedHeader(); |
|
124 CSIPSupportedHeader(const CSIPSupportedHeader& aHeader); |
|
125 |
|
126 private: // For testing purposes |
|
127 |
|
128 UNIT_TEST(CSIPSupportedHeaderTest) |
|
129 }; |
|
130 |
|
131 #endif // CSIPSUPPORTEDHEADER_H |
|
132 |
|
133 // End of File |