1 /* |
|
2 * Copyright (c) 2005 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 "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: CLocalNodeAttribute |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 |
|
21 #ifndef __LOCALNODEATTRIBUTE__ |
|
22 #define __LOCALNODEATTRIBUTE__ |
|
23 |
|
24 #include "XdmNodeAttribute.h" |
|
25 |
|
26 class CLocalProtocol; |
|
27 |
|
28 //CLASS DECLARATION |
|
29 NONSHARABLE_CLASS( CLocalNodeAttribute ) : public CXdmNodeAttribute |
|
30 { |
|
31 public: // Constructors and destructor |
|
32 |
|
33 /** |
|
34 * Two-phased constructor. |
|
35 * |
|
36 * @param TDesC8& Name of this attribute |
|
37 * @param CXdmDocumentNode* Parent of this attribute |
|
38 * |
|
39 * NOTE! "Parent", in this case, denotes the |
|
40 * element this attribute attributes. |
|
41 * |
|
42 * @return CXdmNodeAttribute* |
|
43 */ |
|
44 static CLocalNodeAttribute* NewL( CXdmEngine& aXdmEngine, |
|
45 const TDesC& aAttributeName, |
|
46 CXdmDocumentNode* aParentNode, |
|
47 CLocalProtocol& aLocalProtocol ); |
|
48 |
|
49 /** |
|
50 * Two-phased constructor. |
|
51 * |
|
52 * @param CXdmDocumentNode* Parent of this attribute |
|
53 * |
|
54 * NOTE! "Parent", in this case, denotes the |
|
55 * element this attribute attributes. |
|
56 * |
|
57 * @return CXdmNodeAttribute* |
|
58 */ |
|
59 static CLocalNodeAttribute* NewL( CXdmEngine& aXdmEngine, |
|
60 CXdmDocumentNode* aParentNode, |
|
61 CLocalProtocol& aLocalProtocol ); |
|
62 |
|
63 /** |
|
64 * Destructor. |
|
65 */ |
|
66 virtual ~CLocalNodeAttribute(); |
|
67 |
|
68 public: // New functions |
|
69 |
|
70 |
|
71 |
|
72 private: |
|
73 |
|
74 /** |
|
75 * C++ constructor, private version. |
|
76 */ |
|
77 CLocalNodeAttribute( CXdmEngine& aXdmEngine, |
|
78 CLocalProtocol& aLocalProtocol ); |
|
79 |
|
80 /** |
|
81 * C++ constructor, protected version. |
|
82 * |
|
83 * @param CXdmDocumentNode* The parent node of this element |
|
84 */ |
|
85 CLocalNodeAttribute( CXdmEngine& aXdmEngine, |
|
86 CXdmDocumentNode* aParentNode, |
|
87 CLocalProtocol& aLocalProtocol ); |
|
88 |
|
89 /** |
|
90 * By default Symbian OS constructor is private. |
|
91 * |
|
92 * @param TDesC8& Name of this node |
|
93 * @return void |
|
94 */ |
|
95 void ConstructL( const TDesC& aNodeName ); |
|
96 |
|
97 /** |
|
98 * C++ constructor, another private version. |
|
99 */ |
|
100 CLocalNodeAttribute( const TBool aLeafNode, |
|
101 CXdmDocumentNode* aParentNode ); |
|
102 |
|
103 private: //From MXdmNodeInterface |
|
104 |
|
105 /** |
|
106 * Copies the request data |
|
107 * @param aRequestData Data to be sent |
|
108 */ |
|
109 TPtrC8 Prefix() const; |
|
110 |
|
111 /** |
|
112 * Copies the request data |
|
113 * @param aRequestData Data to be sent |
|
114 */ |
|
115 void SetPrefixL( const TDesC& aNamespacePrefix ); |
|
116 |
|
117 /** |
|
118 * Copies the request data |
|
119 * @param aRequestData Data to be sent |
|
120 */ |
|
121 void SetPrefixL( const TDesC8& aNamespacePrefix ); |
|
122 |
|
123 private: |
|
124 |
|
125 CLocalProtocol& iLocalProtocol; |
|
126 }; |
|
127 |
|
128 #endif //__LOCALNODEATTRIBUTE__ |
|
129 |
|
130 // End of File |
|