Attempt to represent the S^2->S^3 header reorganisation as a series of "hg rename" operations
1 // Copyright (c) 2003-2009 Nokia Corporation and/or its subsidiary(-ies).
2 // All rights reserved.
3 // This component and the accompanying materials are made available
4 // 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
5 // which accompanies this distribution, and is available
6 // at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
8 // Initial Contributors:
9 // Nokia Corporation - initial contribution.
19 #ifndef __STRINGDICTIONARY_H__
20 #define __STRINGDICTIONARY_H__
30 class MStringDictionary
32 This interface defines the API of a single string dictionary.
33 This class is not used directly, but via a derived class the user provides.
34 Derived classes must add all elements, attributes names, and attribute values that belong
35 to this string dictionary as static string tables to the StringPool. WBXML token mappings between
36 strings and WBXML tokens should also be maintained.
46 This method allows for the correct destrution of the string dictionary plugin.
48 @post the objects memory is cleaned up.
51 virtual void Release() = 0;
54 This method returns the element string associated with the given token.
56 @param aToken the element token.
57 @param aElement On return reflects the string corresponding to the token.
58 @leave KErrXmlUnsupportedElement, if the token doesn't correspond to an element.
60 virtual void ElementL(TInt aToken, RString& aElement) const = 0;
63 This method returns the attribute string associated with the given token.
65 @param aToken the attribute token.
66 @param aAttribute On return reflects the string corresponding to the token.
67 @leave KErrXmlUnsupportedAttribute, if the token doesn't correspond to an attribute.
69 virtual void AttributeL(TInt aToken, RString& aAttribute) const = 0;
72 This method returns the attribute and value string associated with the given token.
74 @param aToken the attribute token.
75 @param aAttribute On return reflects the string corresponding to the token.
76 @param aValue On return reflects the string corresponding to the value
78 @leave KErrXmlUnsupportedAttribute, if the token doesn't correspond to an attribute
79 @leave KErrXmlUnsupportedAttributeValue, if the token doesn't correspond to a value
81 virtual void AttributeValuePairL(TInt aToken, RString& aAttribute, RString& aValue) const = 0;
84 This method returns the value string associated with the given token.
86 @param aToken the attribute token.
87 @param aValue On return reflects the string corresponding to the value
89 @leave KErrXmlUnsupportedAttributeValue, if the token doesn't correspond to value.
91 virtual void AttributeValueL(TInt aToken, RString& aValue) const = 0;
95 This method compares the Dictionary description with that provided.
97 @return ETrue if this is the same Dictionary (i.e. a match), EFalse otherwise.
99 @param aDictionaryDescription The description we want to compare.
101 virtual TBool CompareThisDictionary(const RString& aDictionaryDescription) const = 0;
104 This method switches the dictionary to use the specified codepage.
106 @return The codepage switched to, or KErrXmlMissingStringDictionary if it is not supported.
108 @param aCodePage The code page to switch to.
110 virtual TInt SwitchCodePage(TInt aCodePage) = 0;
113 This method obtains the public identifier from the StringTable.
114 Either the formal or non formal public id will do.
115 The stringDictionary .rss files must list both these as wbxml
116 documents have one or the other.
118 @param aPubId The public identifier for this string
122 virtual void PublicIdentifier(RString& aPubId) = 0;
125 The element types in the Device Information DTD are defined within
126 a namespace associated with the Uri/Urn available from the StringTable.
127 The RString need not be closed, but closing is harmless.
129 @param aUri The associated namespace for this string
133 virtual void NamespaceUri(RString& aUri) = 0;
138 #endif //__STRINGDICTIONARY_H__