2 * Copyright (c) 2002-2005 Nokia Corporation and/or its subsidiary(-ies).
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".
9 * Initial Contributors:
10 * Nokia Corporation - initial contribution.
14 * Description: Parser base element class declaration
26 #include <SenBaseElement.h>
29 _LIT8(KSenFacet, "Facet");
30 _LIT8(KFacetAttrName, "name");
31 _LIT8(KFacetAttrType, "type");
34 class CSenFacet : public CSenBaseElement
41 IMPORT_C static CSenFacet* NewL();
45 * @param aCopiedSource source to copy facet data from.
47 IMPORT_C static CSenFacet* NewL(CSenElement& aCopiedSource);
51 * @param aNsUri The namespace URI of the new element
52 * @param aLocalName The local name of the new element
53 * @param aQName The qualified name of the new element
54 * @param aAttributes The attributes of the new element
56 * KErrSenInvalidCharacters if aLocalName or aQName contains
58 * KErrSenZeroLengthDescriptor if aLocalName or aQName is zero length.
60 IMPORT_C static CSenFacet* NewL(const TDesC8& aNsUri,
61 const TDesC8& aLocalName,
63 const RAttributeArray& aAttributes);
65 IMPORT_C virtual ~CSenFacet();
71 * @param aName the name to be set.
73 IMPORT_C virtual void SetNameL(const TDesC8& aName);
77 * @param aType the type to be set.
79 IMPORT_C virtual void SetTypeL(const TDesC8& aType);
83 * @param aValue the value to be set.
85 IMPORT_C virtual void SetValueL(const TDesC8& aValue);
89 * @return the name of the facet
91 IMPORT_C virtual TPtrC8 Name();
95 * @return the type of the facet
97 IMPORT_C virtual TPtrC8 Type();
101 * @return the value of the facet
103 IMPORT_C virtual TPtrC8 Value();
105 virtual void CopyFromL(CSenElement& aSource);
110 * C++ default constructor.
112 IMPORT_C CSenFacet();
115 * By default Symbian 2nd phase constructors are private.
117 IMPORT_C void ConstructL(const TDesC8& aLocalName);
118 IMPORT_C void ConstructL(CSenElement& aCopiedSource);
119 IMPORT_C void ConstructL(const TDesC8& aNsUri,
120 const TDesC8& aLocalName,
121 const TDesC8& aQName,
122 const RAttributeArray& aAttributes);
125 #endif // SEN_FACET_H