1 sippassociateduriheader.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 : sippassociateduriheader.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 CSIPPASSOCIATEDURIHEADER_H |
|
26 #define CSIPPASSOCIATEDURIHEADER_H |
|
27 |
|
28 // INCLUDES |
|
29 #include "sipaddressheaderbase.h" |
|
30 #include "_sipcodecdefs.h" |
|
31 |
|
32 // FORWARD DECLARATIONS |
|
33 class CSIPAddress; |
|
34 class CSIPHeaderGenericParams; |
|
35 |
|
36 // CLASS DECLARATION |
|
37 /** |
|
38 * @publishedAll |
|
39 * @released |
|
40 * |
|
41 * Class provides functions for setting and getting parameters in SIP |
|
42 * "P-Associated-URI" header. |
|
43 * |
|
44 * @lib sipcodec.lib |
|
45 */ |
|
46 class CSIPPAssociatedURIHeader : public CSIPAddressHeaderBase |
|
47 { |
|
48 public: // Constructors and destructor |
|
49 |
|
50 /** |
|
51 * Constructs a CSIPPAssociatedURIHeader from textual representation |
|
52 * of the header's value part. |
|
53 * @param aValue a value part of a "P-Associated-URI"-header |
|
54 * (e.g. "User <user@host>;param=value") |
|
55 * @return an array containing one to many instances |
|
56 * of CSIPPAssociatedURIHeader |
|
57 */ |
|
58 IMPORT_C static RPointerArray<CSIPPAssociatedURIHeader> |
|
59 DecodeL(const TDesC8& aValue); |
|
60 |
|
61 /** |
|
62 * Creates a new instance of CSIPPAssociatedURIHeader |
|
63 * @pre aSIPAddress != 0 |
|
64 * @param aSIPAddress a name-address, the ownership is transferred. |
|
65 * @return a new instance of CSIPPAssociatedURIHeader |
|
66 */ |
|
67 IMPORT_C static CSIPPAssociatedURIHeader* |
|
68 NewL(CSIPAddress* aSIPAddress); |
|
69 |
|
70 /** |
|
71 * Creates a new instance of CSIPPAssociatedURIHeader and |
|
72 * puts it to CleanupStack |
|
73 * @pre aSIPAddress != 0 |
|
74 * @param aSIPAddress a name-address, the ownership is transferred, |
|
75 * @return a new instance of CSIPPAssociatedURIHeader |
|
76 */ |
|
77 IMPORT_C static CSIPPAssociatedURIHeader* |
|
78 NewLC(CSIPAddress* aSIPAddress); |
|
79 |
|
80 /** |
|
81 * Destructor, deletes the resources of CSIPPAssociatedURIHeader. |
|
82 */ |
|
83 IMPORT_C virtual ~CSIPPAssociatedURIHeader(); |
|
84 |
|
85 |
|
86 public: // New functions |
|
87 |
|
88 /** |
|
89 * Constructs an instance of a CSIPPAssociatedURIHeader from |
|
90 * a RReadStream |
|
91 * @param aReadStream a stream containing the value of the |
|
92 * externalized object (header name not included). |
|
93 * @return an instance of a CSIPPAssociatedURIHeader |
|
94 */ |
|
95 IMPORT_C static CSIPHeaderBase* |
|
96 InternalizeValueL(RReadStream& aReadStream); |
|
97 |
|
98 public: // From CSIPHeaderBase |
|
99 |
|
100 /** |
|
101 * From CSIPHeaderBase CloneL |
|
102 */ |
|
103 IMPORT_C CSIPHeaderBase* CloneL() const; |
|
104 |
|
105 /** |
|
106 * From CSIPHeaderBase Name |
|
107 */ |
|
108 IMPORT_C RStringF Name() const; |
|
109 |
|
110 public: // From CSIPHeaderBase, for internal use |
|
111 |
|
112 /** |
|
113 * @internalComponent |
|
114 */ |
|
115 TPreferredPlace PreferredPlaceInMessage() const; |
|
116 |
|
117 /** |
|
118 * @internalComponent |
|
119 */ |
|
120 TBool MoreThanOneAllowed() const; |
|
121 |
|
122 public: // New functions, for internal use |
|
123 |
|
124 static RPointerArray<CSIPHeaderBase> BaseDecodeL(const TDesC8& aValue); |
|
125 |
|
126 private: // Constructors |
|
127 |
|
128 CSIPPAssociatedURIHeader(); |
|
129 |
|
130 private: // For testing purposes |
|
131 |
|
132 UNIT_TEST(CSIPPAssociatedURIHeaderTest) |
|
133 }; |
|
134 |
|
135 #endif // end of CSIPPASSOCIATEDURIHEADER_H |
|
136 |
|
137 // End of File |