dependencies/xcfw/gmxmlnode.h
author kashif.sayed
Fri, 26 Mar 2010 04:17:01 +0530
branchv5backport
changeset 31 a3e98f9c292b
parent 17 c9bafd575d88
permissions -rw-r--r--
added missing files user: kashif.sayed added dependencies/AknTaskList.h added dependencies/DRMEvent.h added dependencies/DRMEventObserver.h added dependencies/DRMNotifier.h added dependencies/SchemeDefs.hrh added dependencies/SchemeHandler.h added dependencies/SchemeHandler.inl added dependencies/aiwcommon.hrh added dependencies/aiwdialdata.h added dependencies/drmrightsinfo.h added dependencies/drmutilitytypes.h added dependencies/javaattribute.h added dependencies/javadomainpskeys.h added dependencies/javaregistry.h added dependencies/javaregistryapplicationentry.h added dependencies/javaregistryentry.h added dependencies/javaregistryentrytype.h added dependencies/javaregistrypackageentry.h added dependencies/mjavaattribute.h added dependencies/swi/bld.inf added dependencies/swi/sispackagetrust.h added dependencies/swi/sisregistryentry.h added dependencies/swi/sisregistrylog.h added dependencies/swi/sisregistrysession.h changed .cproject changed dependencies/S3libs/bld.inf changed dependencies/bld.inf
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
17
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
     1
// Copyright (c) 2001-2009 Nokia Corporation and/or its subsidiary(-ies).
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
     2
// All rights reserved.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
     3
// This component and the accompanying materials are made available
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
     4
// under the terms of "Eclipse Public License v1.0"
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
     5
// which accompanies this distribution, and is available
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
     6
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
     7
//
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
     8
// Initial Contributors:
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
     9
// Nokia Corporation - initial contribution.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    10
//
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    11
// Contributors:
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    12
//
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    13
// Description:
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    14
// This file contains the declaration of the CMDXMLNode class which
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    15
// is the base class for the Mini-DOM.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    16
// 
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    17
//
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    18
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    19
/**
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    20
 @file
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    21
*/
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    22
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    23
#ifndef __GMXMLNODE_H__
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    24
#define __GMXMLNODE_H__
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    25
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    26
#include <e32base.h>
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    27
#ifndef SYMBIAN_ENABLE_SPLIT_HEADERS
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    28
#include <gmxmldocument.h>
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    29
#endif
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    30
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    31
// forward references
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    32
class CMDXMLComposer;
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    33
class CMDXMLDocument;
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    34
class CMDXMLEntityConverter;
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    35
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    36
class CMDXMLNode : public CBase
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    37
/** Abstract base class for DOM node classes.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    38
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    39
It stores the node type and name, and manages a list of child nodes. The node 
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    40
name and type are set in the derived class's constructor and cannot be changed.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    41
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    42
The list of child nodes is managed as a doubly-linked list, not an array 
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    43
or similar structure.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    44
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    45
Derived classes that are not allowed children override the operations to manipulate 
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    46
the child list. 
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    47
@publishedPartner
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    48
@released
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    49
*/
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    50
{
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    51
public:
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    52
	// XML DOM Node Types - The actual values are taken from the DOM definition but we only use some of them.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    53
	/** XML DOM node types.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    54
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    55
	The values are taken from the DOM definition, but only some of them are used 
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    56
	for the SMIL API. 
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    57
@publishedPartner
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    58
@released
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    59
*/
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    60
	enum TDOMNodeType
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    61
		{
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    62
		EElementNode=1,					//< Element
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    63
		ETextNode=3,					//< Text
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    64
		ECDATASectionNode=4,			//< CDATA Section
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    65
		EProcessingInstructionNode=7,	//< Processing Instruction
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    66
		ECommentNode=8,					//< Comment
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    67
		EDocumentNode=9					//< Document
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    68
		};
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    69
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    70
	/** Destructor.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    71
	
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    72
	When a node is deleted, it:
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    73
	
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    74
	1. links its previous and next siblings
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    75
	
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    76
	2. deletes all its children
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    77
	
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    78
	3. corrects its parents first and last child pointers if necessary */
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    79
	IMPORT_C virtual ~CMDXMLNode();
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    80
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    81
	/** Gets the node type of the node.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    82
	
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    83
	@return The node type of the node */
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    84
	inline TDOMNodeType NodeType() {return iNodeType;}
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    85
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    86
	/** Gets the name of the node.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    87
	
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    88
	@return The name of the node */
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    89
	IMPORT_C TPtrC NodeName();
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    90
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    91
	/** Tests if the node can have child nodes.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    92
	
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    93
	@return True if the node can have child nodes, false otherwise */
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    94
	inline TBool CanHaveChildNodes() {return iCanHaveChildren;}
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    95
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    96
	/** Tests if the node has any child nodes.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    97
	
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    98
	@return True if the node has any child nodes, false otherwise */
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
    99
	inline TBool HasChildNodes() {return (iFirstChildPtr != NULL);}
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   100
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   101
	/** Gets a pointer to the document which is the owner of the DOM tree.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   102
	
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   103
	@return A pointer to the document which is the owner of the DOM tree */
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   104
	inline CMDXMLDocument* OwnerDocument() {return (CMDXMLDocument*)iOwnerDocument;}
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   105
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   106
	/** Gets a pointer to the first child node, if any.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   107
	
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   108
	@return A pointer to the first child node if any, otherwise NULL */
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   109
	inline CMDXMLNode* FirstChild() {return iFirstChildPtr;}
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   110
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   111
	/** Gets a pointer to the last child node, if any.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   112
	
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   113
	@return A pointer to the last child node if any, otherwise NULL */
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   114
	inline CMDXMLNode* LastChild() {return iLastChildPtr;}
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   115
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   116
	/** Gets a pointer to the next sibling node, if any.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   117
	
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   118
	@return A pointer to the next sibling node if any, otherwise NULL */
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   119
	inline CMDXMLNode* NextSibling() {return iNextSiblingPtr;}
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   120
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   121
	/** Gets a pointer to the previous sibling node, if any.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   122
	
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   123
	@return A pointer to the previous sibling node if any, otherwise NULL */
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   124
	inline CMDXMLNode* PreviousSibling() {return iPrevSiblingPtr;}
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   125
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   126
	/** Gets a pointer to the parent node, if any.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   127
	
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   128
	@return A pointer to the parent node if any, otherwise NULL (only at root 
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   129
	of tree) */
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   130
	inline CMDXMLNode* ParentNode() {return iParentPtr;}
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   131
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   132
	/** Gets the element type as an enumerated value.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   133
	
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   134
	This function is quicker to use than NodeName().
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   135
	
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   136
	@return A CMDXMLNode::TDomNodeType value identifying the node type */
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   137
	inline TInt ElementType() {return iElementType;}
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   138
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   139
	/** Removes a child from the list of child nodes. 
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   140
	
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   141
	The child node is not deleted: that is the responsibility of the caller.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   142
	
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   143
	@param aChildToRemove Pointer to child to remove from the list
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   144
	@return KErrNone if sucessful or KErrNotFound if the referenced child node 
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   145
	is not found */
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   146
	IMPORT_C TInt RemoveChild(CMDXMLNode* aChildToRemove);
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   147
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   148
	/** Inserts a new child node at a specific point in the child list. 
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   149
	
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   150
	@param aInsertBeforeChild Pointer to the element before which the new child 
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   151
	should be inserted. UseNULL to insert at the start of the list.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   152
	@param aChildToInsert Pointer to the new child node to insert
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   153
	@return KErrNone if successful, KErrNotSupported if the node cannot have children 
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   154
	or KErrNotFound if it cannot find the child before which to insert */
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   155
	IMPORT_C TInt InsertBefore(CMDXMLNode* aInsertBeforeChild, CMDXMLNode* aChildToInsert);
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   156
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   157
	/** Appends a new child at the end of the child list. 
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   158
	
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   159
	@param aChildToInsert Pointer to the new child node to append.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   160
	@return KErrNone if successful or KErrNotSupported if the node cannot have 
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   161
	children */
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   162
	IMPORT_C TInt AppendChild(CMDXMLNode* aChildToInsert);
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   163
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   164
	/** Inserts a new child node while removing an existing one. 
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   165
	
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   166
	The old child is not deleted. 
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   167
	
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   168
	@param aChildToInsert Pointer to the new child node to insert
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   169
	@param aChildToReplace Pointer to the child node to be replaced
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   170
	@return KErrNone if successful, KErrNotSupported if the node cannot have children 
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   171
	or KErrNotFound if it cannot find the child to replace. */
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   172
	IMPORT_C TInt ReplaceChild(CMDXMLNode* aChildToInsert, CMDXMLNode* aChildToReplace);
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   173
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   174
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   175
	/** Checks the children of this node for validity.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   176
	
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   177
	@return True if the children are valid according to the DTD. */
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   178
	IMPORT_C virtual TBool CheckChildren()=0;
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   179
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   180
protected:
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   181
	/*
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   182
	 * The node type will normally be hard-wired in any derived class constructor.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   183
	 * The node name and HaveChildren flag will normally be hard-wired in a derived class constructor unless it
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   184
     * covers a generic element.
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   185
	 * @param aNodeType The tpe of node to be created
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   186
	 * @param aCanHaveChildren Flag to indicate if the node represents a node which is allowed children
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   187
	 * @param aOwnerDocument Pointer to the document at the root of the DOM tree - if NULL then assume this is the root
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   188
	 */
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   189
	CMDXMLNode( TDOMNodeType aNodeType, TBool aCanHaveChildren, CMDXMLDocument* aOwnerDocument );
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   190
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   191
// make these public? sjr
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   192
	/**
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   193
	 * Gets a pointer to the previous sibling node of the same type if any,
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   194
	 * otherwise returns NULL
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   195
	 * @return Previous sibling node
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   196
	 */
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   197
	IMPORT_C CMDXMLNode* PreviousSameTypeSibling();
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   198
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   199
	/**
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   200
	 * Gets a pointer to the next sibling node of the same type if any,
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   201
	 * otherwise returns NULL
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   202
	 * @return Next sibling node
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   203
	 */
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   204
	IMPORT_C CMDXMLNode* NextSameTypeSibling();
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   205
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   206
	/**
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   207
	 * Set the node name - normally on creation
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   208
	 * @param aNodeName The node name - commonly an element tag name - _not_ any unique identifier
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   209
	 * @leave Can Leave due to OOM
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   210
	 */
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   211
	IMPORT_C void SetNodeNameL(const TDesC& aNodeName);
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   212
	
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   213
	/**
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   214
	 * Sets the enumerated element type (same information as node name but faster to access)
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   215
	 */
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   216
	inline void SetElementType( TInt aElementType ) {iElementType = aElementType;}
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   217
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   218
protected:
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   219
	CMDXMLDocument* iOwnerDocument;	//< Pointer to owning document	
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   220
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   221
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   222
private:
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   223
	TInt iElementType;				// Enumerated element type
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   224
	TDOMNodeType iNodeType;			// Node type
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   225
	HBufC* iNodeName;				// Name of the node, e.g. element tag name - not unique id
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   226
	CMDXMLNode* iParentPtr;			// Pointer to parent node if any
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   227
	CMDXMLNode* iFirstChildPtr;		// Pointer to first child node if any
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   228
	CMDXMLNode* iLastChildPtr;		// Pointer to last child node if any
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   229
	CMDXMLNode* iNextSiblingPtr;	// Pointer to next sibling if any
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   230
	CMDXMLNode* iPrevSiblingPtr;	// Pointer to previous sibling if any
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   231
	TBool iCanHaveChildren;			// true if this node is allowed to have children
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   232
};
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   233
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   234
#endif
c9bafd575d88 xcfw component compiles now
jake
parents:
diff changeset
   235
// End Of File