williamr@2: /* williamr@2: * Copyright (c) 2004-2006 Nokia Corporation and/or its subsidiary(-ies). williamr@2: * All rights reserved. williamr@2: * This component and the accompanying materials are made available williamr@2: * 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: * which accompanies this distribution, and is available williamr@2: * at the URL "http://www.symbianfoundation.org/legal/licencesv10.html". williamr@2: * williamr@2: * Initial Contributors: williamr@2: * Nokia Corporation - initial contribution. williamr@2: * williamr@2: * Contributors: williamr@2: * williamr@2: * Description: Text node functions williamr@2: * williamr@2: */ williamr@2: williamr@2: williamr@2: williamr@2: williamr@2: williamr@2: williamr@2: williamr@2: #ifndef XMLENGINE_TEXT_H_INCLUDED williamr@2: #define XMLENGINE_TEXT_H_INCLUDED williamr@2: williamr@2: #include "xmlengcharacterdata.h" williamr@2: williamr@2: williamr@2: williamr@2: /** williamr@2: * The TXmlEngTextNode interface inherits from TXmlEngCharacterData and represents the textual content williamr@2: * (termed "character data" in XML) of an Element or TXmlEngAttr. williamr@2: * williamr@2: * If there is no markup inside an element's content, the text is contained in a single object williamr@2: * of the TXmlEngTextNode interface that is the only child of the element. If there is markup, williamr@2: * it is parsed into the information items (elements, comments, etc.) and TXmlEngTextNode nodes that williamr@2: * form the list of children of the element. williamr@2: * williamr@2: * When a document is first made available via the DOM, there is only one TXmlEngTextNode node for each williamr@2: * block of text. Users may create adjacent TXmlEngTextNode nodes that represent the contents of a given williamr@2: * element without any intervening markup, but should be aware that there is no way to williamr@2: * represent the separations between these nodes in XML or HTML, so they will not (in general) williamr@2: * persist between DOM editing sessions. williamr@2: * williamr@2: * No lexical check is done on the content of a TXmlEngTextNode node and, depending on its position in williamr@2: * the document, some characters must be escaped during serialization using character references; williamr@2: * e.g. the characters "<&" if the textual content is part of an element or of an attribute, williamr@2: * the character sequence "]]>" when part of an element, the quotation mark character " or williamr@2: * the apostrophe character ' when part of an attribute. williamr@2: * williamr@2: * DOM Level 3 spec: williamr@2: *

http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407/core.html#ID-1312295772 williamr@2: * williamr@2: * @lib XmlEngineDOM.lib williamr@2: * @since S60 v3.1 williamr@2: */ williamr@2: class TXmlEngTextNode : public TXmlEngCharacterData williamr@2: { williamr@2: public: williamr@2: /** williamr@2: * Default constructor williamr@2: * williamr@2: * @since S60 v3.1 williamr@2: */ williamr@2: inline TXmlEngTextNode(); williamr@2: williamr@2: /** williamr@2: * Check if element content is whitespace. williamr@2: * williamr@2: * @since S60 v3.1 williamr@2: * @return TRUE if is only whitespace williamr@2: */ williamr@2: IMPORT_C TBool IsElementContentWhitespace() const; williamr@2: williamr@2: protected: williamr@2: /** williamr@2: * Constructor williamr@2: * williamr@2: * @since S60 v3.1 williamr@2: * @param aInternal Text node pointer williamr@2: */ williamr@2: inline TXmlEngTextNode(void* aInternal); williamr@2: }; williamr@2: williamr@2: williamr@2: williamr@2: #include "xmlengtext.inl" williamr@2: williamr@2: #endif /* XMLENGINE_TEXT_H_INCLUDED */