williamr@2
|
1 |
/*
|
williamr@2
|
2 |
* Copyright (c) 2002-2005 Nokia Corporation and/or its subsidiary(-ies).
|
williamr@2
|
3 |
* All rights reserved.
|
williamr@2
|
4 |
* This component and the accompanying materials are made available
|
williamr@2
|
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
|
williamr@2
|
6 |
* which accompanies this distribution, and is available
|
williamr@2
|
7 |
* at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
|
williamr@2
|
8 |
*
|
williamr@2
|
9 |
* Initial Contributors:
|
williamr@2
|
10 |
* Nokia Corporation - initial contribution.
|
williamr@2
|
11 |
*
|
williamr@2
|
12 |
* Contributors:
|
williamr@2
|
13 |
*
|
williamr@2
|
14 |
* Description: Parser base element class declaration
|
williamr@2
|
15 |
*
|
williamr@2
|
16 |
*/
|
williamr@2
|
17 |
|
williamr@2
|
18 |
|
williamr@2
|
19 |
#ifndef SEN_FACET_H
|
williamr@2
|
20 |
#define SEN_FACET_H
|
williamr@2
|
21 |
|
williamr@2
|
22 |
// INCLUDES
|
williamr@2
|
23 |
#include <SenBaseElement.h>
|
williamr@2
|
24 |
|
williamr@2
|
25 |
// CONSTANTS
|
williamr@2
|
26 |
_LIT8(KSenFacet, "Facet");
|
williamr@2
|
27 |
_LIT8(KFacetAttrName, "name");
|
williamr@2
|
28 |
_LIT8(KFacetAttrType, "type");
|
williamr@2
|
29 |
|
williamr@2
|
30 |
// CLASS DECLARATION
|
williamr@2
|
31 |
class CSenFacet : public CSenBaseElement
|
williamr@2
|
32 |
{
|
williamr@2
|
33 |
public:
|
williamr@2
|
34 |
|
williamr@2
|
35 |
/**
|
williamr@2
|
36 |
* Basic constructor.
|
williamr@2
|
37 |
*/
|
williamr@2
|
38 |
IMPORT_C static CSenFacet* NewL();
|
williamr@2
|
39 |
|
williamr@2
|
40 |
/**
|
williamr@2
|
41 |
* Basic constructor.
|
williamr@2
|
42 |
* @param aCopiedSource source to copy facet data from.
|
williamr@2
|
43 |
*/
|
williamr@2
|
44 |
IMPORT_C static CSenFacet* NewL(CSenElement& aCopiedSource);
|
williamr@2
|
45 |
|
williamr@2
|
46 |
/**
|
williamr@2
|
47 |
* Basic constructor.
|
williamr@2
|
48 |
* @param aNsUri The namespace URI of the new element
|
williamr@2
|
49 |
* @param aLocalName The local name of the new element
|
williamr@2
|
50 |
* @param aQName The qualified name of the new element
|
williamr@2
|
51 |
* @param aAttributes The attributes of the new element
|
williamr@2
|
52 |
* Leave codes:
|
williamr@2
|
53 |
* KErrSenInvalidCharacters if aLocalName or aQName contains
|
williamr@2
|
54 |
* illegal characters.
|
williamr@2
|
55 |
* KErrSenZeroLengthDescriptor if aLocalName or aQName is zero length.
|
williamr@2
|
56 |
*/
|
williamr@2
|
57 |
IMPORT_C static CSenFacet* NewL(const TDesC8& aNsUri,
|
williamr@2
|
58 |
const TDesC8& aLocalName,
|
williamr@2
|
59 |
const TDesC8& aQName,
|
williamr@2
|
60 |
const RAttributeArray& aAttributes);
|
williamr@2
|
61 |
|
williamr@2
|
62 |
IMPORT_C virtual ~CSenFacet();
|
williamr@2
|
63 |
|
williamr@2
|
64 |
// New functions
|
williamr@2
|
65 |
|
williamr@2
|
66 |
/**
|
williamr@2
|
67 |
* Setter for name.
|
williamr@2
|
68 |
* @param aName the name to be set.
|
williamr@2
|
69 |
*/
|
williamr@2
|
70 |
IMPORT_C virtual void SetNameL(const TDesC8& aName);
|
williamr@2
|
71 |
|
williamr@2
|
72 |
/**
|
williamr@2
|
73 |
* Setter for type.
|
williamr@2
|
74 |
* @param aType the type to be set.
|
williamr@2
|
75 |
*/
|
williamr@2
|
76 |
IMPORT_C virtual void SetTypeL(const TDesC8& aType);
|
williamr@2
|
77 |
|
williamr@2
|
78 |
/**
|
williamr@2
|
79 |
* Setter for value.
|
williamr@2
|
80 |
* @param aValue the value to be set.
|
williamr@2
|
81 |
*/
|
williamr@2
|
82 |
IMPORT_C virtual void SetValueL(const TDesC8& aValue);
|
williamr@2
|
83 |
|
williamr@2
|
84 |
/**
|
williamr@2
|
85 |
* Getter for name.
|
williamr@2
|
86 |
* @return the name of the facet
|
williamr@2
|
87 |
*/
|
williamr@2
|
88 |
IMPORT_C virtual TPtrC8 Name();
|
williamr@2
|
89 |
|
williamr@2
|
90 |
/**
|
williamr@2
|
91 |
* Getter for type.
|
williamr@2
|
92 |
* @return the type of the facet
|
williamr@2
|
93 |
*/
|
williamr@2
|
94 |
IMPORT_C virtual TPtrC8 Type();
|
williamr@2
|
95 |
|
williamr@2
|
96 |
/**
|
williamr@2
|
97 |
* Getter for value.
|
williamr@2
|
98 |
* @return the value of the facet
|
williamr@2
|
99 |
*/
|
williamr@2
|
100 |
IMPORT_C virtual TPtrC8 Value();
|
williamr@2
|
101 |
|
williamr@2
|
102 |
protected:
|
williamr@2
|
103 |
|
williamr@2
|
104 |
/**
|
williamr@2
|
105 |
* C++ default constructor.
|
williamr@2
|
106 |
*/
|
williamr@2
|
107 |
IMPORT_C CSenFacet();
|
williamr@2
|
108 |
|
williamr@2
|
109 |
/**
|
williamr@2
|
110 |
* By default Symbian 2nd phase constructors are private.
|
williamr@2
|
111 |
*/
|
williamr@2
|
112 |
IMPORT_C void ConstructL(const TDesC8& aLocalName);
|
williamr@2
|
113 |
IMPORT_C void ConstructL(CSenElement& aCopiedSource);
|
williamr@2
|
114 |
IMPORT_C void ConstructL(const TDesC8& aNsUri,
|
williamr@2
|
115 |
const TDesC8& aLocalName,
|
williamr@2
|
116 |
const TDesC8& aQName,
|
williamr@2
|
117 |
const RAttributeArray& aAttributes);
|
williamr@2
|
118 |
};
|
williamr@2
|
119 |
|
williamr@2
|
120 |
#endif // SEN_FACET_H
|
williamr@2
|
121 |
|
williamr@2
|
122 |
// End of File
|