00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #ifndef M_SEN_FRAGMENT_H
00023 #define M_SEN_FRAGMENT_H
00024
00025
00026 #include <e32base.h>
00027 #include <s32strm.h>
00028 #include <xml\Attribute.h>
00029 #include <SenXmlReader.h>
00030 #include <MSenElement.h>
00031
00032
00033 class CSenElement;
00034
00035 using namespace Xml;
00036
00037
00038
00039
00051 class MSenFragment
00052 {
00053 public:
00060 virtual CSenElement& AsElement() = 0;
00061
00072 virtual CSenElement* ExtractElement() = 0;
00073
00080 virtual void SetReader(CSenXmlReader& aReader) = 0;
00081
00089 virtual CSenXmlReader* Reader() = 0;
00090
00100 virtual void ParseL(const TDesC8& aBuf) = 0;
00101
00110 virtual TInt BuildFrom(const TDesC8& aBuf) = 0;
00111
00123 virtual void DelegateParsingL(MSenFragment& aDelegate) = 0;
00124
00141 virtual void DelegateParsingL( const TDesC8& aNsUri,
00142 const TDesC8& aLocalName,
00143 const TDesC8& aQName,
00144 const RAttributeArray& aAttrs) = 0;
00145
00153 virtual void ParseWithL(CSenXmlReader& aReader) = 0;
00154
00160 virtual void SetOwner(MSenFragment& aFragment) = 0;
00161
00171 virtual void ResumeParsingFromL(const TDesC8& aNsUri,
00172 const TDesC8& aLocalName,
00173 const TDesC8& aQName) = 0;
00174
00180 virtual void SetAttributesL(const RAttributeArray& aAttrs) = 0;
00181
00191 virtual void WriteStartElementL(const TDesC8& aNsUri,
00192 const TDesC8& aLocalName,
00193 const TDesC8& aQName,
00194 const RAttributeArray& aAttrs) = 0;
00195
00204 virtual void WriteEndElementL(const TDesC8& aNsUri,
00205 const TDesC8& aLocalName,
00206 const TDesC8& aQName) = 0;
00207
00213 virtual const TDesC8& LocalName() const = 0;
00214
00220 virtual const TDesC8& NsUri() const = 0;
00221
00227 virtual const TDesC8& NsPrefix() const = 0;
00228
00234 virtual void WriteAsXMLToL(RWriteStream& aWriteStream) = 0;
00235
00241 virtual HBufC* AsXmlUnicodeL() = 0;
00242
00248 virtual HBufC8* AsXmlL() = 0;
00249
00260 virtual TBool ConsistsOfL(MSenFragment& aCandidate) = 0;
00261 };
00262
00263 #endif // M_SEN_FRAGMENT_H
00264
00265