From 1e90661bb817402f85103c3b9d3ce6ebab570f38 Mon Sep 17 00:00:00 2001 From: Daniel Veillard Date: Fri, 5 Dec 2003 14:57:46 +0000 Subject: [PATCH] cleanup the make rebuild in doc, this include new directive to stop * globals.c xmlwriter.c doc/apibuild.py include/libxml/globals.h include/libxml/pattern.h include/libxml/schemasInternals.h include/libxml/xmlexports.h include/libxml/xmlwriter.h: cleanup the make rebuild in doc, this include new directive to stop documentation warnings * doc/* doc/html/*: rebuilt the docs * pattern.c xmlreader.c include/libxml/pattern.h include/libxml/xmlreader.h: adding xmlTextReaderPreservePattern() to save nodes while scanning the tree with the reader, cleanup the way element were freed, and xmlTextReaderPreserve() implementation, the API might change for namespace binding support when compiling patterns. * doc/examples/*: added reader3.c exposing the xmlTextReaderPreserve() Daniel --- ChangeLog | 16 ++ doc/APIchunk0.html | 2 +- doc/APIchunk1.html | 2 +- doc/APIchunk10.html | 12 +- doc/APIchunk11.html | 5 +- doc/APIchunk12.html | 2 +- doc/APIchunk13.html | 8 +- doc/APIchunk14.html | 1 + doc/APIchunk15.html | 3 +- doc/APIchunk16.html | 1 + doc/APIchunk17.html | 12 + doc/APIchunk18.html | 3 +- doc/APIchunk19.html | 2 + doc/APIchunk20.html | 7 +- doc/APIchunk21.html | 3 +- doc/APIchunk22.html | 5 +- doc/APIchunk23.html | 1 + doc/APIchunk24.html | 6 +- doc/APIchunk25.html | 6 + doc/APIchunk3.html | 2 +- doc/APIchunk4.html | 2 - doc/APIchunk6.html | 4 +- doc/APIchunk7.html | 2 + doc/APIchunk8.html | 5 +- doc/APIconstructors.html | 165 ++++++------- doc/APIfiles.html | 13 +- doc/APIfunctions.html | 8 + doc/APIsymbols.html | 7 + doc/apibuild.py | 64 ++++-- doc/examples/.cvsignore | 1 + doc/examples/Makefile.am | 10 +- doc/examples/examples.xml | 37 +++ doc/examples/index.html | 2 +- doc/examples/reader3.c | 104 +++++++++ doc/examples/reader3.out | 13 ++ doc/examples/test3.xml | 39 ++++ doc/html/book1.html | 2 +- doc/html/index.html | 2 +- doc/html/libxml-lib.html | 2 +- doc/html/libxml-parserInternals.html | 2 +- doc/html/libxml-relaxng.html | 2 +- doc/html/libxml-schemasInternals.html | 6 +- doc/html/libxml-xmlexports.html | 2 +- doc/html/libxml-xmlreader.html | 5 +- doc/html/libxml-xmlversion.html | 2 +- doc/html/libxml-xmlwriter.html | 14 +- doc/libxml2-api.xml | 62 ++++- doc/libxml2-refs.xml | 319 +++++++++++++++++--------- globals.c | 4 + include/libxml/globals.h | 1 + include/libxml/pattern.h | 2 +- include/libxml/schemasInternals.h | 20 +- include/libxml/xmlexports.h | 2 + include/libxml/xmlreader.h | 3 + include/libxml/xmlwriter.h | 25 ++ pattern.c | 4 +- python/libxml2class.txt | 1 + win32/libxml2.def.src | 5 + xmlreader.c | 135 ++++++++++- xmlwriter.c | 2 +- 60 files changed, 923 insertions(+), 276 deletions(-) create mode 100644 doc/examples/reader3.c create mode 100644 doc/examples/reader3.out create mode 100644 doc/examples/test3.xml diff --git a/ChangeLog b/ChangeLog index d8f88a75..1c1e255e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,19 @@ +Fri Dec 5 15:49:44 CET 2003 Daniel Veillard + + * globals.c xmlwriter.c doc/apibuild.py include/libxml/globals.h + include/libxml/pattern.h include/libxml/schemasInternals.h + include/libxml/xmlexports.h include/libxml/xmlwriter.h: cleanup + the make rebuild in doc, this include new directive to stop + documentation warnings + * doc/* doc/html/*: rebuilt the docs + * pattern.c xmlreader.c include/libxml/pattern.h + include/libxml/xmlreader.h: adding xmlTextReaderPreservePattern() + to save nodes while scanning the tree with the reader, cleanup + the way element were freed, and xmlTextReaderPreserve() + implementation, the API might change for namespace binding support + when compiling patterns. + * doc/examples/*: added reader3.c exposing the xmlTextReaderPreserve() + Thu Dec 4 15:10:57 CET 2003 Daniel Veillard * python/libxml.py: oops forgot to modify/commit the new code. diff --git a/doc/APIchunk0.html b/doc/APIchunk0.html index 93642086..8bbf43f4 100644 --- a/doc/APIchunk0.html +++ b/doc/APIchunk0.html @@ -126,6 +126,7 @@ A:link, A:visited, A:active { text-decoration: underline }
Applies
htmlCtxtUseOptions
xmlCtxtUseOptions
xmlNormalizeURIPath
+
Apply
XML_SCHEMAS_ANYATTR_STRICT
Arabic
xmlUCSIsArabic
ArabicPresentationForms-A
xmlUCSIsArabicPresentationFormsA
ArabicPresentationForms-B
xmlUCSIsArabicPresentationFormsB
@@ -222,7 +223,6 @@ A:link, A:visited, A:active { text-decoration: underline }
Blocks
xmlStopParser
Bopomofo
xmlUCSIsBopomofo
BopomofoExtended
xmlUCSIsBopomofoExtended
-
Borland
XMLCALL
Both
XML_SUBSTITUTE_BOTH
BoxDrawing
xmlUCSIsBoxDrawing
BraillePatterns
xmlUCSIsBraillePatterns
diff --git a/doc/APIchunk1.html b/doc/APIchunk1.html index 99dbcc69..486ec75e 100644 --- a/doc/APIchunk1.html +++ b/doc/APIchunk1.html @@ -229,6 +229,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlSchemaCompareValues
xmlXPathCmpNodes
Compile
xmlAutomataCompile
+xmlPatterncompile
xmlXPathCompile
xmlXPathStringEvalNumber
Compress
docbCreateFileParserCtxt
@@ -320,7 +321,6 @@ A:link, A:visited, A:active { text-decoration: underline } xmlNanoHTTPInit
xmlTextReaderNextSibling
Cut
xmlReconciliateNs
-
Cygwin
XMLCALL
CypriotSyllabary
xmlUCSIsCypriotSyllabary
Cyrillic
xmlUCSIsCyrillic
CyrillicSupplement
xmlUCSIsCyrillicSupplement
diff --git a/doc/APIchunk10.html b/doc/APIchunk10.html index b5a87a37..f3ea4f2e 100644 --- a/doc/APIchunk10.html +++ b/doc/APIchunk10.html @@ -212,6 +212,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlXPathSubstringFunction
xmlXPathTranslateFunction
charencoding
xmlGetCharEncodingName
+
chars??
xmlTextWriterWriteRawLen
charset
xmlAllocParserInputBuffer
xmlCreateIOParserCtxt
xmlIOParseDTD
@@ -381,7 +382,9 @@ A:link, A:visited, A:active { text-decoration: underline }
common
_xmlDoc
_xmlDtd
_xmlNode
-
comp
xmlXPathFreeCompExpr
+
comp
xmlFreePattern
+xmlFreePatternList
+xmlXPathFreeCompExpr
compare
xmlListDataCompare
xmlUTF8Charcmp
xmlXPathCompareValues
@@ -411,7 +414,9 @@ A:link, A:visited, A:active { text-decoration: underline } xmlRootNode
compatible
LIBXML_TEST_VERSION
xmlShellPwd
-
compilation
xmlXPathCompile
+
compilation
xmlPatterncompile
+xmlXPathCompile
+
compile
xmlPatterncompile
compile-time
docbCreateFileParserCtxt
docbParseFile
docbSAXParseFile
@@ -436,6 +441,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlAutomataCompile
xmlCheckVersion
xmlGetLastError
+xmlPatterncompile
xmlRegexpCompile
xmlRegexpExec
xmlRegexpIsDeterminist
@@ -448,7 +454,6 @@ A:link, A:visited, A:active { text-decoration: underline } xmlCleanupOutputCallbacks
xmlRegisterDefaultInputCallbacks
xmlRegisterDefaultOutputCallbacks
-
compiler
XMLCALL
compiling
xmlRelaxNGNewDocParserCtxt
complement
xmlXPathStringEvalNumber
complete
XML_COMPLETE_ATTRS
@@ -662,7 +667,6 @@ A:link, A:visited, A:active { text-decoration: underline } xmlNanoFTPConnectTo
xmlSAX2ResolveEntity
conveniently
xmlCurrentChar
-
convention
XMLCALL
conversion
_xmlXPathType
xmlCharEncOutFunc
xmlParseEncodingDecl
diff --git a/doc/APIchunk11.html b/doc/APIchunk11.html index 6301dae7..eea44c91 100644 --- a/doc/APIchunk11.html +++ b/doc/APIchunk11.html @@ -116,8 +116,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlTextWriterWriteVFormatDTD
xmlValidateNotationDecl
xmlXPtrBuildNodeList
-
declare
XMLCALL
-xmlParseEntityRef
+
declare
xmlParseEntityRef
xmlParserHandleReference
xmlSearchNs
declared
_xmlElement
@@ -339,6 +338,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlDictQLookup
xmlDictReference
xmlDictSize
+xmlPatterncompile
did
xmlTextReaderGetRemainder
difference
xmlXPathDifference
differenciate
xmlXPathOrderDocElems
@@ -465,6 +465,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlKeepBlanksDefault
xmlNodeListGetRawString
xmlParserInputRead
+xmlPatternMatch
xmlRemoveProp
xmlUTF8Strlen
xmlValidateRoot
diff --git a/doc/APIchunk12.html b/doc/APIchunk12.html index 585e2053..f6133a45 100644 --- a/doc/APIchunk12.html +++ b/doc/APIchunk12.html @@ -74,6 +74,7 @@ A:link, A:visited, A:active { text-decoration: underline } htmlNodeStatus
xlinkIsLink
xmlDictSize
+xmlFreePatternList
xmlHashSize
xmlLineNumbersDefault
xmlListMerge
@@ -336,7 +337,6 @@ A:link, A:visited, A:active { text-decoration: underline } xmlSchemaNewMemParserCtxt
xmlSchemaNewParserCtxt
explored
xmlXPathAxisFunc
-
exported
XMLCALL
exposing
xmlTextReaderRead
expression
_xmlXPathContext
_xmlXPathParserContext
diff --git a/doc/APIchunk13.html b/doc/APIchunk13.html index 6f9d5972..4011faca 100644 --- a/doc/APIchunk13.html +++ b/doc/APIchunk13.html @@ -89,6 +89,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlNanoHTTPOpenRedir
xmlNanoHTTPSave
xmlNewAutomata
+xmlPatternMatch
xmlRelaxNGGetParserErrors
xmlSaveFile
xmlSaveFileEnc
@@ -167,6 +168,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlCleanupParser
xmlSkipBlankChars
xmlTextReaderCurrentDoc
+xmlTextReaderPreservePattern
firs
xmlCharEncOutFunc
fist
xmlEntityReferenceFunc
fit
xmlCharEncFirstLine
@@ -184,7 +186,8 @@ A:link, A:visited, A:active { text-decoration: underline } xmlTextReaderIsValid
flagged
_htmlElemDesc
htmlGetMetaEncoding
-
flags
xmlReaderForDoc
+
flags
xmlPatterncompile
+xmlReaderForDoc
xmlReaderForFd
xmlReaderForFile
xmlReaderForIO
@@ -327,8 +330,7 @@ A:link, A:visited, A:active { text-decoration: underline }
functionality
xmlNewGlobalNs
xmlXPathNodeSetGetLength
xmlXPathNodeSetItem
-
functions
XMLCALL
-htmlCtxtReadIO
+
functions
htmlCtxtReadIO
htmlReadIO
xmlC14NDocDumpMemory
xmlCtxtReadIO
diff --git a/doc/APIchunk14.html b/doc/APIchunk14.html index a05e154c..e3f87024 100644 --- a/doc/APIchunk14.html +++ b/doc/APIchunk14.html @@ -174,6 +174,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlSAXParseMemoryWithData
xmlSchemaSetParserErrors
xmlSetGenericErrorFunc
+xmlTextReaderPreservePattern
handled
xmlLoadACatalog
xmlParseAttValue
xmlParseAttribute
diff --git a/doc/APIchunk15.html b/doc/APIchunk15.html index f646b5af..2e0ed366 100644 --- a/doc/APIchunk15.html +++ b/doc/APIchunk15.html @@ -401,7 +401,8 @@ A:link, A:visited, A:active { text-decoration: underline } xmlRelaxNGNewDocParserCtxt
xmlRemoveID
xmlRemoveRef
-
interned
xmlTextReaderConstString
+
interned
xmlPatterncompile
+xmlTextReaderConstString
interoperability
xmlParseElementChildrenContentDecl
interprestation
xmlXPathFunction
interpreter
xmlXPathAxisFunc
diff --git a/doc/APIchunk16.html b/doc/APIchunk16.html index 061a8c3f..cf10ba88 100644 --- a/doc/APIchunk16.html +++ b/doc/APIchunk16.html @@ -51,6 +51,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlXPtrNewContext

Letter k:

keep
xmlParserInputGrow
xmlSubstituteEntitiesDefault
+xmlTextReaderPreservePattern
xmlXPathNextNamespace
keeps
xmlGetBufferAllocationScheme
xmlSetBufferAllocationScheme
diff --git a/doc/APIchunk17.html b/doc/APIchunk17.html index 5488718e..73b81138 100644 --- a/doc/APIchunk17.html +++ b/doc/APIchunk17.html @@ -34,6 +34,11 @@ A:link, A:visited, A:active { text-decoration: underline } u-w x-x

Letter m:

machine
xmlCheckFilename
+
macro
xmlTextWriterEndDTDAttlist
+xmlTextWriterEndDTDElement
+xmlTextWriterEndDTDEntity
+xmlTextWriterWriteDocType
+xmlTextWriterWriteProcessingInstruction
made
LIBXML_ISO8859X_ENABLED
xmlCharEncOutFunc
xmlNodeListGetRawString
@@ -68,6 +73,11 @@ A:link, A:visited, A:active { text-decoration: underline }
many
_xmlParserInput
xmlXPathStringFunction
maps
xmlTextReaderLookupNamespace
+xmlTextWriterEndDTDAttlist
+xmlTextWriterEndDTDElement
+xmlTextWriterEndDTDEntity
+xmlTextWriterWriteDocType
+xmlTextWriterWriteProcessingInstruction
mark
xmlStrcat
xmlStrdup
xmlTextReaderQuoteChar
@@ -87,6 +97,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlParseExternalSubset
xmlParseMarkupDecl
masked
xmlReconciliateNs
+
matched
xmlTextReaderPreservePattern
matches
CHECK_ARITY
xmlFileMatch
xmlIOFTPMatch
@@ -94,6 +105,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlParseCtxtExternalEntity
xmlParseExtParsedEnt
xmlParseExternalEntity
+xmlPatternMatch
xmlRegexpExec
xmlValidateDtdFinal
matching
xmlFileMatch
diff --git a/doc/APIchunk18.html b/doc/APIchunk18.html index c1c20be5..c0457387 100644 --- a/doc/APIchunk18.html +++ b/doc/APIchunk18.html @@ -158,7 +158,8 @@ A:link, A:visited, A:active { text-decoration: underline }
nodes2
xmlXPathDifference
nodeset
xmlXPathNodeSetFreeNs
nodesets
xmlXPathNodeSetMerge
-
non
xmlEncodeEntitiesReentrant
+
non
XML_SCHEMAS_ANYATTR_LAX
+xmlEncodeEntitiesReentrant
xmlNewChild
xmlNewTextChild
xmlXPathParseNCName
diff --git a/doc/APIchunk19.html b/doc/APIchunk19.html index 2c2b3670..4d62a35e 100644 --- a/doc/APIchunk19.html +++ b/doc/APIchunk19.html @@ -125,6 +125,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlParsePI
xmlParseStartTag
xmlTextReaderCurrentDoc
+xmlTextReaderPreservePattern
xmlValidateDocumentFinal
xmlValidateDtdFinal
xmlXPathNodeSetMerge
@@ -209,6 +210,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlNewTextChild
xmlNodeDumpOutput
xmlParseMisc
+xmlPatterncompile
xmlSchemaValidateStream
xmlShellSave
xmlShellValidate
diff --git a/doc/APIchunk20.html b/doc/APIchunk20.html index bb964943..3bcbc46d 100644 --- a/doc/APIchunk20.html +++ b/doc/APIchunk20.html @@ -115,6 +115,9 @@ A:link, A:visited, A:active { text-decoration: underline } xmlShellPwd
xmlShellValidate
xmlTextReaderRelaxNGValidate
+
pattern
xmlPatternMatch
+xmlPatterncompile
+xmlTextReaderPreservePattern
pcdata
cdataBlock
cdataBlockSAXFunc
xmlSAX2CDataBlock
@@ -142,7 +145,6 @@ A:link, A:visited, A:active { text-decoration: underline } xmlReplaceNode
places
xmlStrPrintf
xmlStrVPrintf
-
platform
XMLCALL
plug
xmlXPathFuncLookupFunc
xmlXPathVariableLookupFunc
plus
UTF8ToHtml
@@ -184,6 +186,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlSchemaValidateFacet
xmlSchemaValidatePredefinedType
xmlSchemaValidateStream
+xmlTextReaderPreservePattern
xmlValidateNCName
xmlValidateNMToken
xmlValidateName
@@ -225,6 +228,7 @@ A:link, A:visited, A:active { text-decoration: underline }
preceding-sibling
xmlXPathNextPrecedingSibling
precisely
xmlXPathSubstringFunction
precompiled
_xmlXPathParserContext
+xmlPatternMatch
xmlRegNewExecCtxt
xmlRelaxNGNewValidCtxt
xmlSchemaNewValidCtxt
@@ -273,6 +277,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlNodeSetSpacePreserve
xmlParserInputGrow
xmlParserInputRead
+xmlTextReaderPreservePattern
preserved
HTML_PRESERVE_NODE
xmlParserInputBufferGrow
preserving
xmlNodeGetSpacePreserve
diff --git a/doc/APIchunk21.html b/doc/APIchunk21.html index 73786858..043ad629 100644 --- a/doc/APIchunk21.html +++ b/doc/APIchunk21.html @@ -551,7 +551,8 @@ A:link, A:visited, A:active { text-decoration: underline } xmlSAXUserParseMemory
rule
xmlParseEntityRef
xmlParseStartTag
-
rules
xmlXPathSubstringFunction
+
rules
XML_SCHEMAS_ANYATTR_STRICT
+xmlXPathSubstringFunction
run
_xmlParserCtxt
running
xmlKeepBlanksDefault
runtime
XML_MAX_NAMELEN
diff --git a/doc/APIchunk22.html b/doc/APIchunk22.html index 8f91dad2..91409430 100644 --- a/doc/APIchunk22.html +++ b/doc/APIchunk22.html @@ -423,6 +423,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlNewChild
xmlNewDocNode
xmlNewDocNodeEatName
+xmlTextWriterWriteRawLen
specialized
xmlGcMemGet
xmlGcMemSetup
specific
XML_CATALOG_PI
@@ -588,7 +589,8 @@ A:link, A:visited, A:active { text-decoration: underline } xmlTextReaderRead
streams
_xmlParserCtxt
xmlSkipBlankChars
-
strict
xmlParseExternalID
+
strict
XML_SCHEMAS_ANYATTR_STRICT
+xmlParseExternalID
xmlXPathCompareValues
string--that
xmlNormalizeURIPath
string-length
xmlXPathStringLengthFunction
@@ -597,6 +599,7 @@ A:link, A:visited, A:active { text-decoration: underline }
stringi
xmlXPathSubstringAfterFunction
strings
_xmlParserCtxt
xmlGetFeaturesList
+xmlPatterncompile
xmlRegexpCompile
stripping
xmlXPathNormalizeFunction
strncasecmp
xmlStrncasecmp
diff --git a/doc/APIchunk23.html b/doc/APIchunk23.html index f475b8c5..5cd6cb96 100644 --- a/doc/APIchunk23.html +++ b/doc/APIchunk23.html @@ -60,6 +60,7 @@ A:link, A:visited, A:active { text-decoration: underline } XML_DETECT_IDS
XML_SKIP_IDS
_htmlElemDesc
+
tells
xmlTextReaderPreservePattern
temporary
_xmlValidCtxt
_xmlXPathContext
xmlIOHTTPOpenW
diff --git a/doc/APIchunk24.html b/doc/APIchunk24.html index a0da7098..50252917 100644 --- a/doc/APIchunk24.html +++ b/doc/APIchunk24.html @@ -43,6 +43,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlGetDocCompressMode
xmlSetCompressMode
xmlSetDocCompressMode
+
undefined
xmlPatterncompile
under
xmlSearchNs
xmlSetTreeDoc
xmlShellDu
@@ -67,7 +68,8 @@ A:link, A:visited, A:active { text-decoration: underline } xmlValidateOneAttribute
xmlValidateOneNamespace
units
xmlUTF8Strsub
-
unknown
XML_SCHEMAS_FACET_UNKNOWN
+
unknown
XML_SCHEMAS_ANYATTR_SKIP
+XML_SCHEMAS_FACET_UNKNOWN
htmlCtxtUseOptions
xmlCtxtUseOptions
xmlUCSIsBlock
@@ -298,10 +300,12 @@ A:link, A:visited, A:active { text-decoration: underline } xmlXIncludeProcessNode
xmlXIncludeProcessTree
wether
_xmlNodeSet
+xmlPatternMatch
what
xmlCatalogGetDefaults
xmlCatalogSetDefaults
xmlParseNamespace
xmlTextReaderGetRemainder
+xmlTextWriterWriteRawLen
where
_htmlElemDesc
xmlCopyProp
xmlCopyPropList
diff --git a/doc/APIchunk25.html b/doc/APIchunk25.html index e8b5b0ae..7c6b29c4 100644 --- a/doc/APIchunk25.html +++ b/doc/APIchunk25.html @@ -372,9 +372,15 @@ A:link, A:visited, A:active { text-decoration: underline } xmlTextReaderCurrentDoc
xmlTextReaderCurrentNode
xmlTextReaderPreserve
+
xmlTextReaderCurrentDoc
xmlTextReaderPreservePattern
xmlTextReaderLocatorPtr
xmlTextReaderLocatorBaseURI
xmlTextReaderLocatorLineNumber
xmlTextReaderRead
xmlTextReaderExpand
+
xmlTextWriterEndDTD
xmlTextWriterEndDTDAttlist
+xmlTextWriterEndDTDElement
+xmlTextWriterEndDTDEntity
+
xmlTextWriterWriteDTD
xmlTextWriterWriteDocType
+
xmlTextWriterWritePI
xmlTextWriterWriteProcessingInstruction
xmlURI
xmlCreateURI
xmlFreeURI
xmlPrintURI
diff --git a/doc/APIchunk3.html b/doc/APIchunk3.html index 269e004d..9c968357 100644 --- a/doc/APIchunk3.html +++ b/doc/APIchunk3.html @@ -113,7 +113,6 @@ A:link, A:visited, A:active { text-decoration: underline }
GET
xmlNanoHTTPFetch
xmlNanoHTTPOpen
xmlNanoHTTPOpenRedir
-
GNU
XMLCALL
GeneralPunctuation
xmlUCSIsGeneralPunctuation
Generic
xmlCharEncCloseFunc
xmlCharEncInFunc
@@ -242,6 +241,7 @@ A:link, A:visited, A:active { text-decoration: underline } IS_LETTER
xmlIsLetter
IdeographicDescriptionCharacters
xmlUCSIsIdeographicDescriptionCharacters
+
Ignore
XML_SCHEMAS_ANYATTR_LAX
Ignored
xmlCopyChar
Implements
xmlShell
xmlShellBase
diff --git a/doc/APIchunk4.html b/doc/APIchunk4.html index 00f04952..310cce82 100644 --- a/doc/APIchunk4.html +++ b/doc/APIchunk4.html @@ -112,7 +112,6 @@ A:link, A:visited, A:active { text-decoration: underline }
MUST
xmlC14NDocSaveTo
xmlC14NExecute
xmlTextReaderNormalization
-
Macros
XMLCALL
Makes
xmlAutomataSetFinalState
Malayalam
xmlUCSIsMalayalam
Markup
xmlParseExternalSubset
@@ -132,7 +131,6 @@ A:link, A:visited, A:active { text-decoration: underline } htmlSetMetaEncoding
Method
xmlTextReaderGetRemainder
Mime-Type
xmlNanoHTTPMimeType
-
Mingw
XMLCALL
Misc
xmlParseDocument
xmlParseMisc
MiscellaneousMathematicalSymbols-A
xmlUCSIsMiscellaneousMathematicalSymbolsA
diff --git a/doc/APIchunk6.html b/doc/APIchunk6.html index 6a3972f7..6281f66f 100644 --- a/doc/APIchunk6.html +++ b/doc/APIchunk6.html @@ -61,6 +61,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlTextReaderGetParserProp
xmlTextReaderRelaxNGSetSchema
xmlTextReaderRelaxNGValidate
+
Reader
xmlTextReaderPreservePattern
Readers
xmlTextReaderNextSibling
Reads
xmlTextReaderCurrentNode
xmlTextReaderExpand
@@ -386,7 +387,8 @@ A:link, A:visited, A:active { text-decoration: underline } xmlStrdup
xmlTextReaderNormalization
Sinhala
xmlUCSIsSinhala
-
Skip
xmlNextChar
+
Skip
XML_SCHEMAS_ANYATTR_SKIP
+xmlNextChar
xmlParseComment
xmlTextReaderNext
xmlTextReaderNextSibling
diff --git a/doc/APIchunk7.html b/doc/APIchunk7.html index bca2c724..7d96b513 100644 --- a/doc/APIchunk7.html +++ b/doc/APIchunk7.html @@ -64,6 +64,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlParserHandleReference
xmlParserInputBufferGrow
xmlScanName
+xmlTextWriterWriteRawLen
xmlXPathNextAttribute
TRUE
xmlTextWriterStartDTDEntity
xmlTextWriterWriteDTDEntity
@@ -87,6 +88,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlStringLenDecodeEntities
Tamil
xmlUCSIsTamil
Telugu
xmlUCSIsTelugu
+
Test
xmlPatternMatch
Text
xmlNodeIsText
xmlTextReaderReadAttributeValue
xmlTextReaderReadString
diff --git a/doc/APIchunk8.html b/doc/APIchunk8.html index 5314f4f0..f31e653f 100644 --- a/doc/APIchunk8.html +++ b/doc/APIchunk8.html @@ -108,7 +108,6 @@ A:link, A:visited, A:active { text-decoration: underline }
Whitespace
xmlXPathNormalizeFunction
Will
xmlSaveFile
xmlSaveFormatFile
-
Windows
XMLCALL
With
xmlParseAttribute
xmlParseEndTag
xmlParseStartTag
@@ -184,6 +183,8 @@ A:link, A:visited, A:active { text-decoration: underline } xmlXPtrRangeToFunction
XSLT
_xmlNode
_xmlXPathContext
+xmlFreePattern
+xmlFreePatternList
xmlXPathNewValueTree
xmlXPathStackIsNodeSet
Xinclude
XINCLUDE_NS
@@ -228,6 +229,7 @@ A:link, A:visited, A:active { text-decoration: underline }
about
_xmlParserCtxt
xmlDebugDumpString
xmlShellDir
+xmlTextWriterWriteRawLen
above
xmlParseMarkupDecl
xmlXPathSubstringFunction
absoluteURI
xmlParseURI
@@ -479,6 +481,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlHasProp
xmlKeepBlanksDefault
xmlNanoFTPProxy
+xmlTextReaderPreservePattern
xmlXPathStringEvalNumber
alternative
xmlTextWriterStartDTD
xmlTextWriterWriteDTD
diff --git a/doc/APIconstructors.html b/doc/APIconstructors.html index 1ab8da7b..f977640e 100644 --- a/doc/APIconstructors.html +++ b/doc/APIconstructors.html @@ -8,36 +8,36 @@ H2 {font-family: Verdana,Arial,Helvetica} H3 {font-family: Verdana,Arial,Helvetica} A:link, A:visited, A:active { text-decoration: underline } List of constructors for libxml2
Action against software patentsGnome2 LogoW3C LogoRed Hat Logo
Made with Libxml2 Logo

The XML C parser and toolkit of Gnome

List of constructors for libxml2

Developer Menu
API Indexes
Related links

Type const htmlElemDesc *:

htmlTagLookup
-

Type const htmlEntityDesc *:

htmlEntityValueLookup
+

Type const htmlEntityDesc *:

htmlEntityLookup
+htmlEntityValueLookup
htmlParseEntityRef
-htmlEntityLookup
-

Type const xmlChar *:

xmlXPathNsLookup
-xmlStrstr
+

Type const xmlChar *:

xmlStrstr
+xmlXPathNsLookup
xmlEncodeEntities
htmlGetMetaEncoding
xmlTextReaderConstLocalName
xmlParseName
-getSystemId
namePop
+xmlStrcasestr
xmlDictLookup
xmlCatalogGetPublic
-xmlStrcasestr
+xmlTextReaderConstBaseUri
xmlStrchr
-xmlSplitQName3
xmlParseEncodingDecl
xmlBufferContent
xmlTextReaderConstString
+getSystemId
xmlCatalogGetSystem
xmlSAX2GetPublicId
-xmlTextReaderConstXmlLang
xmlTextReaderConstName
+xmlTextReaderConstXmlLang
getPublicId
xmlTextReaderConstNamespaceUri
xmlTextReaderConstValue
xmlParsePITarget
xmlParseStartTag
xmlDictQLookup
-xmlTextReaderConstBaseUri
+xmlSplitQName3
xmlParseAttribute
xmlTextReaderConstPrefix
xmlSAX2GetSystemId
@@ -46,8 +46,8 @@ A:link, A:visited, A:active { text-decoration: underline } docbSAXParseDoc
docbParseFile
docbSAXParseFile
-

Type docbParserCtxtPtr:

docbCreatePushParserCtxt
-docbCreateFileParserCtxt
+

Type docbParserCtxtPtr:

docbCreateFileParserCtxt
+docbCreatePushParserCtxt

Type double:

xmlXPathCastNodeToNumber
xmlXPathCastStringToNumber
xmlXPathCastToNumber
@@ -56,8 +56,8 @@ A:link, A:visited, A:active { text-decoration: underline } xmlXPathPopNumber
xmlXPathCastBooleanToNumber

Type htmlDocPtr:

htmlParseDoc
+htmlReadIO
htmlCtxtReadFile
-htmlReadMemory
htmlSAXParseDoc
htmlCtxtReadFd
htmlSAXParseFile
@@ -66,43 +66,43 @@ A:link, A:visited, A:active { text-decoration: underline } htmlCtxtReadMemory
htmlCtxtReadDoc
htmlNewDocNoDtD
+htmlReadMemory
htmlParseFile
htmlReadDoc
htmlNewDoc
-htmlReadIO
htmlReadFd
-

Type htmlParserCtxtPtr:

htmlCreateFileParserCtxt
-htmlCreatePushParserCtxt
+

Type htmlParserCtxtPtr:

htmlCreatePushParserCtxt
+htmlCreateFileParserCtxt
htmlCreateMemoryParserCtxt
-

Type htmlStatus:

htmlNodeStatus
+

Type htmlStatus:

htmlElementStatusHere
htmlAttrAllowed
-htmlElementStatusHere
+htmlNodeStatus

Type long:

xmlXPathOrderDocElems
xmlGetLineNo

Type unsigned long:

xmlParserFindNodeInfoIndex

Type void *:

xmlNanoHTTPMethod
-xmlMallocAtomicLoc
xmlMemRealloc
xmlLinkGetData
xmlHashLookup3
-xmlHashLookup2
xmlReallocFunc
xmlNanoFTPConnectTo
-xmlNanoHTTPMethodRedir
xmlOutputOpenCallback
+xmlHashLookup2
xmlHashLookup
xmlHashQLookup
+xmlListReverseSearch
+xmlInputOpenCallback
xmlNanoHTTPOpen
xmlHashQLookup2
xmlReallocLoc
-xmlInputOpenCallback
xmlXPathPopExternal
-xmlCatalogAddLocal
xmlListSearch
+xmlNanoHTTPMethodRedir
xmlNanoFTPNewCtxt
xmlMallocFunc
xmlIOHTTPOpenW
xmlNanoHTTPOpenRedir
+xmlCatalogAddLocal
xmlIOFTPOpen
xmlIOHTTPOpen
xmlNanoFTPOpen
@@ -110,22 +110,22 @@ A:link, A:visited, A:active { text-decoration: underline } xmlHashQLookup3
xmlMallocLoc
xmlHashCopier
+xmlMallocAtomicLoc
xmlFileOpen
-xmlListReverseSearch

Type xlinkHandlerPtr:

xlinkGetDefaultHandler

Type xlinkNodeDetectFunc:

xlinkGetDefaultDetect

Type xlinkType:

xlinkIsLink

Type xmlAttrPtr:

xmlGetID
xmlNewProp
+xmlHasNsProp
xmlNewNsProp
-xmlSetProp
xmlCopyPropList
xmlNewDocProp
xmlSetNsProp
xmlHasProp
xmlNewNsPropEatName
xmlCopyProp
-xmlHasNsProp
+xmlSetProp

Type xmlAttributePtr:

xmlAddAttributeDecl
xmlGetDtdQAttrDesc
xmlGetDtdAttrDesc
@@ -134,9 +134,9 @@ A:link, A:visited, A:active { text-decoration: underline }

Type xmlAutomataStatePtr:

xmlAutomataNewCountedTrans
xmlAutomataNewState
xmlAutomataGetInitState
+xmlAutomataNewEpsilon
xmlAutomataNewTransition2
xmlAutomataNewCounterTrans
-xmlAutomataNewEpsilon
xmlAutomataNewCountTrans
xmlAutomataNewAllTrans
xmlAutomataNewTransition
@@ -156,53 +156,52 @@ A:link, A:visited, A:active { text-decoration: underline } xmlScanName
xmlValidCtxtNormalizeAttributeValue
xmlGetNoNsProp
+xmlStrcat
xmlTextReaderReadOuterXml
xmlNodeListGetRawString
xmlTextReaderNamespaceUri
-xmlStrcat
+xmlCatalogResolvePublic
xmlXPathPopString
-xmlCharStrdup
+xmlTextReaderReadString
xmlCatalogResolveSystem
xmlParseAttValue
xmlNodeListGetString
+xmlSplitQName
xmlBuildQName
xmlGetNodePath
xmlSaveUri
xmlXPathParseNCName
xmlEncodeEntitiesReentrant
-xmlStrdup
xmlXPathCastToString
xmlBuildURI
xmlXPathCastBooleanToString
xmlStringDecodeEntities
xmlParseEncName
xmlTextReaderPrefix
-xmlDecodeEntities
-xmlUTF8Strndup
-xmlGetNsProp
xmlXPathCastNumberToString
xmlParseNmtoken
+xmlTextReaderLocatorBaseURI
xmlTextReaderXmlLang
xmlURIEscape
xmlStringLenDecodeEntities
xmlTextReaderGetAttributeNo
xmlTextReaderGetAttributeNs
-xmlSplitQName
xmlEncodeSpecialChars
xmlURIEscapeStr
-xmlTextReaderLocatorBaseURI
+xmlGetNsProp
+xmlDecodeEntities
xmlXPathCastNodeToString
xmlNamespaceParseNCName
xmlCatalogResolveURI
xmlXPathParseName
xmlGetProp
xmlACatalogResolveURI
+xmlStrndup
+xmlTextReaderValue
xmlNamespaceParseQName
xmlCatalogResolve
xmlParseVersionNum
xmlParseSystemLiteral
-xmlTextReaderLookupNamespace
-xmlXPathCastNodeSetToString
xmlValidNormalizeAttributeValue
xmlTextReaderLocalName
xmlParsePubidLiteral
@@ -210,26 +209,27 @@ A:link, A:visited, A:active { text-decoration: underline } xmlACatalogResolvePublic
xmlACatalogResolveSystem
xmlParseExternalID
+xmlStrdup
xmlStrncat
xmlACatalogResolve
xmlTextReaderBaseUri
xmlParseEntityValue
xmlUTF8Strpos
-xmlCatalogResolvePublic
+xmlCharStrdup
xmlNamespaceParseNSDef
xmlUTF8Strsub
-xmlStrndup
-xmlTextReaderValue
xmlTextReaderReadInnerXml
+xmlXPathCastNodeSetToString
xmlStrsub
xmlCatalogLocalResolveURI
+xmlUTF8Strndup
xmlCharStrndup
xmlParseVersionInfo
xmlNodeGetContent
xmlTextReaderName
xmlSplitQName2
+xmlTextReaderLookupNamespace
xmlNodeGetLang
-xmlTextReaderReadString
xmlTextReaderGetAttribute
xmlCatalogLocalResolve
xmlCanonicPath
@@ -247,7 +247,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlSAXParseMemoryWithData
xmlSAXParseEntity
xmlParseEntity
-xmlCtxtReadFile
+xmlRecoverDoc
xmlSAXParseFileWithData
xmlReadDoc
xmlReadMemory
@@ -256,23 +256,23 @@ A:link, A:visited, A:active { text-decoration: underline } xmlReadFile
xmlRecoverFile
xmlSAXParseDoc
+xmlParseCatalogFile
+xmlCtxtReadFile
xmlCtxtReadFd
xmlReadIO
xmlCopyDoc
xmlCtxtReadMemory
xmlReadFd
-xmlParseCatalogFile
xmlCtxtReadDoc
xmlParseMemory
xmlSAXParseFile
xmlParseFile
xmlTextReaderCurrentDoc
xmlNewDoc
-xmlRecoverDoc
-

Type xmlDtdPtr:

xmlCopyDtd
+

Type xmlDtdPtr:

xmlIOParseDTD
+xmlCopyDtd
xmlGetIntSubset
xmlCreateIntSubset
-xmlIOParseDTD
xmlSAXParseDTD
xmlParseDTD
xmlNewDtd
@@ -288,23 +288,23 @@ A:link, A:visited, A:active { text-decoration: underline } xmlCopyEntitiesTable

Type xmlEntityPtr:

xmlGetDocEntity
xmlParseEntityRef
+getEntity
xmlSAX2GetEntity
xmlGetPredefinedEntity
xmlSAX2GetParameterEntity
getParameterEntity
-getEntity
+xmlAddDocEntity
getParameterEntitySAXFunc
xmlGetDtdEntity
xmlGetParameterEntity
getEntitySAXFunc
xmlAddDtdEntity
-xmlAddDocEntity

Type xmlEnumerationPtr:

xmlCreateEnumeration
xmlParseNotationType
xmlCopyEnumeration
xmlParseEnumerationType
-

Type xmlErrorPtr:

xmlGetLastError
-xmlCtxtGetLastError
+

Type xmlErrorPtr:

xmlCtxtGetLastError
+xmlGetLastError

Type xmlExternalEntityLoader:

xmlGetExternalEntityLoader

Type xmlGlobalStatePtr:

xmlGetGlobalState

Type xmlHashTablePtr:

xmlHashCreate
@@ -315,18 +315,17 @@ A:link, A:visited, A:active { text-decoration: underline }

Type xmlListPtr:

xmlGetRefs
xmlListCreate
xmlListDup
-

Type xmlLocationSetPtr:

xmlXPtrLocationSetCreate
-xmlXPtrLocationSetMerge
+

Type xmlLocationSetPtr:

xmlXPtrLocationSetMerge
+xmlXPtrLocationSetCreate

Type xmlMutexPtr:

xmlNewMutex

Type xmlNodePtr:

xmlXPathNextAncestorOrSelf
-xmlXPathNextAncestor
xmlTextReaderExpand
xmlAddSibling
+xmlXPathNextAncestor
xmlXPathNextPrecedingSibling
xmlNewDocNode
xmlDocCopyNode
nodePop
-xmlXPathNextDescendant
xmlDocGetRootElement
xmlAddPrevSibling
xmlStringGetNodeList
@@ -342,31 +341,32 @@ A:link, A:visited, A:active { text-decoration: underline } xmlNewComment
xmlXPathNextFollowingSibling
xmlNewDocComment
+xmlXPathNextChild
+xmlDocSetRootElement
xmlCopyNodeList
xmlNewTextLen
xmlAddNextSibling
-xmlStringLenGetNodeList
xmlNewNode
-xmlAddChildList
xmlNewDocTextLen
-xmlNewPI
-xmlDocSetRootElement
-xmlXPathNextAttribute
-xmlNewCharRef
-xmlGetLastChild
xmlNewDocRawNode
-xmlXPathNextChild
+xmlNewPI
+xmlNewCharRef
+xmlXPathNextAttribute
+xmlGetLastChild
+xmlAddChildList
xmlXPathNextPreceding
xmlTextMerge
-xmlXPathNextSelf
xmlReplaceNode
+xmlXPathNextSelf
xmlNewNodeEatName
+xmlXPathNextDescendant
xmlNewCDataBlock
xmlNewDocNodeEatName
xmlXPathNextFollowing
xmlNewTextChild
xmlAddChild
xmlXPathNextParent
+xmlStringLenGetNodeList
xmlTextReaderCurrentNode
xmlXPathNextDescendantOrSelf

Type xmlNodeSetPtr:

xmlXPathTrailing
@@ -382,33 +382,33 @@ A:link, A:visited, A:active { text-decoration: underline } xmlXPathNodeLeadingSorted
xmlXPathPopNodeSet
xmlXPathLeadingSorted
-xmlXPathDistinct
xmlXPathNodeTrailingSorted
+xmlXPathDistinct

Type xmlNotationPtr:

xmlGetDtdNotationDesc
xmlAddNotationDecl

Type xmlNotationTablePtr:

xmlCopyNotationTable

Type xmlNsPtr:

xmlCopyNamespaceList
getNamespace
-xmlSearchNs
xmlCopyNamespace
+xmlSearchNs
xmlNewNs
xmlSearchNsByHref
xmlNewGlobalNs
xmlSAX2GetNamespace

Type xmlNsPtr *:

xmlGetNsList

Type xmlOutputBufferPtr:

xmlAllocOutputBuffer
-xmlOutputBufferCreateFile
xmlOutputBufferCreateFd
xmlOutputBufferCreateFilename
+xmlOutputBufferCreateFile
xmlOutputBufferCreateIO

Type xmlParserCtxtPtr:

xmlCreateMemoryParserCtxt
xmlCreateURLParserCtxt
-xmlCreateDocParserCtxt
xmlCreateIOParserCtxt
xmlCreateFileParserCtxt
+xmlCreateDocParserCtxt
+xmlCreateEntityParserCtxt
xmlCreatePushParserCtxt
xmlNewParserCtxt
-xmlCreateEntityParserCtxt

Type xmlParserInputBufferPtr:

xmlParserInputBufferCreateFilename
xmlParserInputBufferCreateMem
xmlAllocParserInputBuffer
@@ -418,11 +418,11 @@ A:link, A:visited, A:active { text-decoration: underline } xmlParserInputBufferCreateIO
xmlParserInputBufferCreateStatic

Type xmlParserInputPtr:

xmlLoadExternalEntity
+xmlNewEntityInputStream
xmlExternalEntityLoader
resolveEntity
xmlCheckHTTPInput
inputPop
-xmlNewEntityInputStream
xmlNewInputFromFile
xmlNewInputStream
xmlNewStringInputStream
@@ -430,6 +430,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlNewIOInputStream
xmlSAX2ResolveEntity
resolveEntitySAXFunc
+

Type xmlPatternPtr:

xmlPatterncompile

Type xmlRMutexPtr:

xmlNewRMutex

Type xmlRefPtr:

xmlAddRef

Type xmlRegExecCtxtPtr:

xmlRegNewExecCtxt
@@ -438,8 +439,8 @@ A:link, A:visited, A:active { text-decoration: underline }

Type xmlRegisterNodeFunc:

xmlRegisterNodeDefault
xmlThrDefRegisterNodeDefault

Type xmlRelaxNGParserCtxtPtr:

xmlRelaxNGNewParserCtxt
-xmlRelaxNGNewDocParserCtxt
xmlRelaxNGNewMemParserCtxt
+xmlRelaxNGNewDocParserCtxt

Type xmlRelaxNGPtr:

xmlRelaxNGParse

Type xmlRelaxNGValidCtxtPtr:

xmlRelaxNGNewValidCtxt

Type xmlSchemaFacetPtr:

xmlSchemaNewFacet
@@ -450,15 +451,15 @@ A:link, A:visited, A:active { text-decoration: underline }

Type xmlSchemaTypePtr:

xmlSchemaGetPredefinedType

Type xmlSchemaValidCtxtPtr:

xmlSchemaNewValidCtxt

Type xmlTextReaderPtr:

xmlReaderForFile
-xmlReaderForFd
-xmlNewTextReader
-xmlReaderWalker
xmlReaderForIO
+xmlNewTextReader
+xmlReaderForFd
+xmlReaderWalker
xmlNewTextReaderFilename
xmlReaderForDoc
xmlReaderForMemory
-

Type xmlTextWriterPtr:

xmlNewTextWriter
-xmlNewTextWriterDoc
+

Type xmlTextWriterPtr:

xmlNewTextWriterDoc
+xmlNewTextWriter
xmlNewTextWriterFilename
xmlNewTextWriterMemory
xmlNewTextWriterPushParser
@@ -477,12 +478,10 @@ A:link, A:visited, A:active { text-decoration: underline } xmlXPathNewNodeSetList
xmlXPathNewFloat
xmlXPathNewString
-xmlXPtrNewLocationSetNodeSet
-xmlXPathConvertString
xmlXPathAxisFunc
-xmlXPathNewNodeSet
-xmlXPathEvalExpression
xmlXPtrNewRangePoints
+xmlXPathConvertString
+xmlXPtrNewLocationSetNodeSet
xmlXPathNewValueTree
xmlXPtrNewLocationSetNodes
xmlXPathWrapNodeSet
@@ -490,22 +489,24 @@ A:link, A:visited, A:active { text-decoration: underline } xmlXPathObjectCopy
xmlXPtrNewRangeNodes
valuePop
-xmlXPtrNewCollapsedRange
+xmlXPathNewNodeSet
+xmlXPathVariableLookupFunc
xmlXPathWrapString
+xmlXPtrNewCollapsedRange
+xmlXPathConvertNumber
xmlXPtrNewRangeNodePoint
xmlXPathNewBoolean
xmlXPtrWrapLocationSet
-xmlXPathWrapExternal
xmlXPathEval
-xmlXPathVariableLookupFunc
xmlXPathNewCString
xmlXPathCompiledEval
xmlXPtrNewRange
+xmlXPathEvalExpression
xmlXPathVariableLookupNS
xmlXPathVariableLookup
xmlXPtrNewRangeNodeObject
xmlXPathConvertBoolean
xmlXPtrEval
-xmlXPathConvertNumber
+xmlXPathWrapExternal

Type xmlXPathParserContextPtr:

xmlXPathNewParserContext

Daniel Veillard

diff --git a/doc/APIfiles.html b/doc/APIfiles.html index b5a2a50f..9b64301b 100644 --- a/doc/APIfiles.html +++ b/doc/APIfiles.html @@ -863,6 +863,12 @@ A:link, A:visited, A:active { text-decoration: underline } IS_PUBIDCHAR_CH
IS_CHAR_CH
xmlParseEntityDecl
+

Module pattern:

xmlFreePattern
+xmlFreePatternList
+xmlPatterncompile
+xmlPatternMatch
+xmlPatternPtr
+xmlPattern

Module relaxng:

xmlRelaxNGFreeValidCtxt
XML_RELAXNG_ERR_DUPID
XML_RELAXNG_ERR_VALELEM
@@ -2128,14 +2134,14 @@ A:link, A:visited, A:active { text-decoration: underline } xmlTextReaderGetParserProp
xmlTextReaderPrefix
xmlTextReaderMoveToAttribute
-xmlTextReaderQuoteChar
+xmlTextReaderPtr
XML_READER_TYPE_END_ENTITY
xmlTextReaderNextSibling
xmlTextReaderGetRemainder
xmlTextReaderReadString
xmlTextReaderIsValid
xmlTextReaderMoveToFirstAttribute
-xmlTextReaderPtr
+xmlTextReaderPreservePattern
xmlTextReaderGetAttribute
xmlTextReaderConstValue
xmlTextReaderLocatorPtr
@@ -2159,6 +2165,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlParserSeverities
xmlTextReaderMoveToNextAttribute
XML_PARSER_SEVERITY_VALIDITY_ERROR
+xmlTextReaderReadAttributeValue
xmlReaderNewWalker
xmlReaderNewDoc
xmlTextReaderConstPrefix
@@ -2191,7 +2198,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlTextReaderNamespaceUri
XML_PARSER_SEVERITY_VALIDITY_WARNING
xmlTextReaderRelaxNGSetSchema
-xmlTextReaderReadAttributeValue
+xmlTextReaderQuoteChar
xmlTextReaderHasValue
xmlTextReaderConstBaseUri

Module xmlregexp:

xmlRegFreeExecCtxt
diff --git a/doc/APIfunctions.html b/doc/APIfunctions.html index f99d7b0b..5832dda8 100644 --- a/doc/APIfunctions.html +++ b/doc/APIfunctions.html @@ -412,6 +412,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlParseExternalEntity
xmlParseExternalSubset
xmlParseExternalSubset
+xmlPatterncompile
xmlReadDoc
xmlReaderForDoc
xmlReaderNewDoc
@@ -523,6 +524,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlTextReaderMoveToAttribute
xmlTextReaderMoveToAttributeNs
xmlTextReaderMoveToAttributeNs
+xmlTextReaderPreservePattern
xmlTextWriterStartAttribute
xmlTextWriterStartAttributeNS
xmlTextWriterStartAttributeNS
@@ -1239,6 +1241,7 @@ A:link, A:visited, A:active { text-decoration: underline }

Type xmlCharEncodingOutputFunc:

xmlNewCharEncodingHandler

Type xmlDeregisterNodeFunc:

xmlDeregisterNodeDefault
xmlThrDefDeregisterNodeDefault
+

Type xmlDict *:

xmlPatterncompile

Type xmlDictPtr:

xmlDictFree
xmlDictLookup
xmlDictOwns
@@ -1603,6 +1606,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlNodeSetLang
xmlNodeSetName
xmlNodeSetSpacePreserve
+xmlPatternMatch
xmlReconciliateNs
xmlRegisterNodeFunc
xmlRelaxNGValidateFullElement
@@ -1909,6 +1913,9 @@ A:link, A:visited, A:active { text-decoration: underline }

Type xmlParserNodeInfoSeqPtr:

xmlClearNodeInfoSeq
xmlInitNodeInfoSeq

Type xmlParserSeverities:

xmlTextReaderErrorFunc
+

Type xmlPatternPtr:

xmlFreePattern
+xmlFreePatternList
+xmlPatternMatch

Type xmlRMutexPtr:

xmlFreeRMutex
xmlRMutexLock
xmlRMutexUnlock
@@ -2081,6 +2088,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlTextReaderNormalization
xmlTextReaderPrefix
xmlTextReaderPreserve
+xmlTextReaderPreservePattern
xmlTextReaderQuoteChar
xmlTextReaderRead
xmlTextReaderReadAttributeValue
diff --git a/doc/APIsymbols.html b/doc/APIsymbols.html index 004580aa..0cdcee1d 100644 --- a/doc/APIsymbols.html +++ b/doc/APIsymbols.html @@ -1479,6 +1479,8 @@ A:link, A:visited, A:active { text-decoration: underline } xmlFreeNsList
xmlFreeParserCtxt
xmlFreeParserInputBuffer
+xmlFreePattern
+xmlFreePatternList
xmlFreeProp
xmlFreePropList
xmlFreeRMutex
@@ -1934,6 +1936,10 @@ A:link, A:visited, A:active { text-decoration: underline } xmlParserValidityWarning
xmlParserVersion
xmlParserWarning
+xmlPattern
+xmlPatternMatch
+xmlPatternPtr
+xmlPatterncompile
xmlPedanticParserDefault
xmlPedanticParserDefaultValue
xmlPopInput
@@ -2270,6 +2276,7 @@ A:link, A:visited, A:active { text-decoration: underline } xmlTextReaderNormalization
xmlTextReaderPrefix
xmlTextReaderPreserve
+xmlTextReaderPreservePattern
xmlTextReaderPtr
xmlTextReaderQuoteChar
xmlTextReaderRead
diff --git a/doc/apibuild.py b/doc/apibuild.py index 223214de..b2543c0a 100755 --- a/doc/apibuild.py +++ b/doc/apibuild.py @@ -27,8 +27,6 @@ ignored_files = { "testOOM.c": "out of memory tester", "testOOMlib.h": "out of memory tester", "testOOMlib.c": "out of memory tester", - "pattern.c": "not integrated yet", - "pattern.h": "not integrated yet", } ignored_words = { @@ -513,10 +511,17 @@ class CParser: self.last_comment = "" self.comment = None self.collect_ref = 0 + self.no_error = 0 def collect_references(self): self.collect_ref = 1 + def stop_error(self): + self.no_error = 1 + + def start_error(self): + self.no_error = 0 + def lineno(self): return self.lexer.getlineno() @@ -529,7 +534,15 @@ class CParser: self.index.add_ref(name, module, static, type, self.lineno(), info, extra) + def warning(self, msg): + if self.no_error: + return + print msg + def error(self, msg, token=-1): + if self.no_error: + return + print "Parse Error: " + msg if token != -1: print "Got token ", token @@ -578,6 +591,13 @@ class CParser: else: self.comment = self.comment + token[1] token = self.lexer.token() + + if string.find(self.comment, "DOC_DISABLE") != -1: + self.stop_error() + + if string.find(self.comment, "DOC_ENABLE") != -1: + self.start_error() + return token # @@ -592,19 +612,19 @@ class CParser: if self.comment == None: if not quiet: - print "Missing comment for macro %s" % (name) + self.warning("Missing comment for macro %s" % (name)) return((args, desc)) if self.comment[0] != '*': if not quiet: - print "Missing * in macro comment for %s" % (name) + self.warning("Missing * in macro comment for %s" % (name)) return((args, desc)) lines = string.split(self.comment, '\n') if lines[0] == '*': del lines[0] if lines[0] != "* %s:" % (name): if not quiet: - print "Misformatted macro comment for %s" % (name) - print " Expecting '* %s:' got '%s'" % (name, lines[0]) + self.warning("Misformatted macro comment for %s" % (name)) + self.warning(" Expecting '* %s:' got '%s'" % (name, lines[0])) return((args, desc)) del lines[0] while lines[0] == '*': @@ -617,8 +637,8 @@ class CParser: arg=string.strip(arg) except: if not quiet: - print "Misformatted macro comment for %s" % (name) - print " problem with '%s'" % (lines[0]) + self.warning("Misformatted macro comment for %s" % (name)) + self.warning(" problem with '%s'" % (lines[0])) del lines[0] continue del lines[0] @@ -647,7 +667,7 @@ class CParser: if quiet == 0: if desc == "": - print "Macro comment for %s lack description of the macro" % (name) + self.warning("Macro comment for %s lack description of the macro" % (name)) return((args, desc)) @@ -668,19 +688,19 @@ class CParser: if self.comment == None: if not quiet: - print "Missing comment for function %s" % (name) + self.warning("Missing comment for function %s" % (name)) return(((ret[0], retdesc), args, desc)) if self.comment[0] != '*': if not quiet: - print "Missing * in function comment for %s" % (name) + self.warning("Missing * in function comment for %s" % (name)) return(((ret[0], retdesc), args, desc)) lines = string.split(self.comment, '\n') if lines[0] == '*': del lines[0] if lines[0] != "* %s:" % (name): if not quiet: - print "Misformatted function comment for %s" % (name) - print " Expecting '* %s:' got '%s'" % (name, lines[0]) + self.warning("Misformatted function comment for %s" % (name)) + self.warning(" Expecting '* %s:' got '%s'" % (name, lines[0])) return(((ret[0], retdesc), args, desc)) del lines[0] while lines[0] == '*': @@ -694,8 +714,8 @@ class CParser: arg=string.strip(arg) except: if not quiet: - print "Misformatted function comment for %s" % (name) - print " problem with '%s'" % (lines[0]) + self.warning("Misformatted function comment for %s" % (name)) + self.warning(" problem with '%s'" % (lines[0])) del lines[0] continue del lines[0] @@ -716,8 +736,8 @@ class CParser: i = i + 1 if i >= nbargs: if not quiet: - print "Unable to find arg %s from function comment for %s" % ( - arg, name) + self.warning("Unable to find arg %s from function comment for %s" % ( + arg, name)) while len(lines) > 0 and lines[0] == '*': del lines[0] desc = "" @@ -754,12 +774,12 @@ class CParser: i = 0 while i < nbargs: if args[i][2] == None and args[i][0] != "void" and args[i][1] != None: - print "Function comment for %s lack description of arg %s" % (name, args[i][1]) + self.warning("Function comment for %s lack description of arg %s" % (name, args[i][1])) i = i + 1 if retdesc == "" and ret[0] != "void": - print "Function comment for %s lack description of return value" % (name) + self.warning("Function comment for %s lack description of return value" % (name)) if desc == "": - print "Function comment for %s lack description of the function" % (name) + self.warning("Function comment for %s lack description of the function" % (name)) return(((ret[0], retdesc), args, desc)) @@ -1016,7 +1036,7 @@ class CParser: try: value = "%d" % (int(value) + 1) except: - print "Failed to compute value of enum %s" % (name) + self.warning("Failed to compute value of enum %s" % (name)) value="" if token[0] == "sep" and token[1] == ",": token = self.token() @@ -1364,7 +1384,7 @@ class CParser: return token def parse(self): - print "Parsing %s" % (self.filename) + self.warning("Parsing %s" % (self.filename)) token = self.token() while token != None: if token[0] == 'name': diff --git a/doc/examples/.cvsignore b/doc/examples/.cvsignore index 30fd579d..17222712 100644 --- a/doc/examples/.cvsignore +++ b/doc/examples/.cvsignore @@ -9,3 +9,4 @@ tree2 testWriter reader1 reader2 +reader3 diff --git a/doc/examples/Makefile.am b/doc/examples/Makefile.am index ebcf18e1..e1e9b50f 100644 --- a/doc/examples/Makefile.am +++ b/doc/examples/Makefile.am @@ -19,9 +19,9 @@ install-data-local: $(mkinstalldirs) $(DESTDIR)$(TARGET_DIR) -@INSTALL@ -m 0644 $(srcdir)/*.html $(srcdir)/*.c $(srcdir)/*.xml $(srcdir)/*.xsl $(srcdir)/*.out $(DESTDIR)$(TARGET_DIR) -EXTRA_DIST=examples.xsl index.py test1.xml examples.xml test2.xml writer.xml tree1.out tree2.out reader1.out +EXTRA_DIST=examples.xsl index.py test1.xml examples.xml test2.xml writer.xml test3.xml tree1.out tree2.out reader1.out reader3.out -noinst_PROGRAMS=xpath1 parse1 parse2 tree1 tree2 testWriter reader1 reader2 +noinst_PROGRAMS=xpath1 parse1 parse2 tree1 tree2 testWriter reader1 reader2 reader3 xpath1_SOURCES=xpath1.c xpath1_LDFLAGS= @@ -63,6 +63,11 @@ reader2_LDFLAGS= reader2_DEPENDENCIES= $(DEPS) reader2_LDADD= @RDL_LIBS@ $(LDADDS) +reader3_SOURCES=reader3.c +reader3_LDFLAGS= +reader3_DEPENDENCIES= $(DEPS) +reader3_LDADD= @RDL_LIBS@ $(LDADDS) + tests: $(noinst_PROGRAMS) @(parse1 test1.xml) @(parse2 test2.xml) @@ -71,5 +76,6 @@ tests: $(noinst_PROGRAMS) @(testWriter ; for i in 1 2 3 4 ; do diff writer.xml writer$$i.out ; done ; rm writer*.out) @(reader1 test2.xml > reader1.tmp ; diff reader1.tmp reader1.out ; rm reader1.tmp) @(reader2 test2.xml > reader1.tmp ; diff reader1.tmp reader1.out ; rm reader1.tmp) + @(reader3 > reader3.tmp ; diff reader3.tmp reader3.out ; rm reader3.tmp) diff --git a/doc/examples/examples.xml b/doc/examples/examples.xml index 5d938bf5..3ee9cb5b 100644 --- a/doc/examples/examples.xml +++ b/doc/examples/examples.xml @@ -227,6 +227,28 @@ + + Show how to extract subdocuments with xmlReader + Demonstrate the use of xmlTextReaderPreservePattern() to parse an XML file with the xmlReader while collecting only some subparts of the document + reader3 + reader3 > reader3.tmp ; diff reader3.tmp reader3.out ; rm reader3.tmp + Daniel Veillard + see Copyright for the status of this software. +

xmlReader
+ + <libxml/xmlreader.h> + + + + + + + + + + + + @@ -282,6 +304,9 @@ + + + @@ -290,6 +315,7 @@ + @@ -315,6 +341,7 @@ + @@ -379,6 +406,7 @@ + @@ -407,6 +435,9 @@ + + + @@ -426,13 +457,18 @@ + + + + + @@ -501,6 +537,7 @@
+
diff --git a/doc/examples/index.html b/doc/examples/index.html index df4f4d85..e2520f5c 100644 --- a/doc/examples/index.html +++ b/doc/examples/index.html @@ -8,4 +8,4 @@ H2 {font-family: Verdana,Arial,Helvetica} H3 {font-family: Verdana,Arial,Helvetica} A:link, A:visited, A:active { text-decoration: underline } Libxml2 set of examples
Action against software patentsGnome2 LogoW3C LogoRed Hat Logo
Made with Libxml2 Logo

Libxml2 set of examples

Examples Menu
Related links

The examples are stored per section depending on the main focus - of the example:

Parsing Examples

parse1.c: Parse an XML file to a tree and free it

Demonstrate the use of xmlReadFile() to read an XML file into a tree and and xmlFreeDoc() to free the resulting tree

Includes:

Uses:

Usage:

parse1 test1.xml

Author: Daniel Veillard

parse2.c: Parse and validate an XML file to a tree and free the result

Create a parser context for an XML file, then parse and validate the file, creating a tree, check the validation result and xmlFreeDoc() to free the resulting tree.

Includes:

Uses:

Usage:

parse2 test2.xml

Author: Daniel Veillard

Tree Examples

tree1.c: Navigates a tree to print element names

Parse a file to a tree, use xmlDocGetRootElement() to get the root element, then walk the document and print all the element name in document order.

Includes:

Uses:

Usage:

tree1 filename_or_URL

Author: Dodji Seketeli

tree2.c: Creates a tree

Shows how to create document, nodes and dump it to stdout or file.

Includes:

Uses:

Usage:

tree2 <filename> -Default output: stdout

Author: Lucas Brasilino <brasilino@recife.pe.gov.br>

XPath Examples

xpath1.c: Evaluate XPath expression and prints result node set.

Shows how to evaluate XPath expression and register known namespaces in XPath context.

Includes:

Uses:

Usage:

xpath1 <xml-file> <xpath-expr> [<known-ns-list>]

Author: Aleksey Sanin

xmlReader Examples

reader1.c: Parse an XML file with an xmlReader

Demonstrate the use of xmlReaderForFile() to parse an XML file and dump the informations about the nodes found in the process

Includes:

Uses:

Usage:

reader1 <filename>

Author: Daniel Veillard

reader2.c: Parse and validate an XML file with an xmlReader

Demonstrate the use of xmlReaderForFile() to parse an XML file validating the content in the process and activating options like entities substitution, and DTD attributes defaulting

Includes:

Uses:

Usage:

reader2 <valid_xml_filename>

Author: Daniel Veillard

xmlWriter Examples

testWriter.c: use various APIs for the xmlWriter

tests a number of APIs for the xmlWriter, especially the various methods to write to a filename, to a memory buffer, to a new document, or to a subtree. It shows how to do encoding string conversions too. The resulting documents are then serialized.

Includes:

Uses:

Usage:

testWriter

Author: Alfred Mickautsch

Daniel Veillard

+ of the example:

Parsing Examples

parse1.c: Parse an XML file to a tree and free it

Demonstrate the use of xmlReadFile() to read an XML file into a tree and and xmlFreeDoc() to free the resulting tree

Includes:

Uses:

Usage:

parse1 test1.xml

Author: Daniel Veillard

parse2.c: Parse and validate an XML file to a tree and free the result

Create a parser context for an XML file, then parse and validate the file, creating a tree, check the validation result and xmlFreeDoc() to free the resulting tree.

Includes:

Uses:

Usage:

parse2 test2.xml

Author: Daniel Veillard

Tree Examples

tree1.c: Navigates a tree to print element names

Parse a file to a tree, use xmlDocGetRootElement() to get the root element, then walk the document and print all the element name in document order.

Includes:

Uses:

Usage:

tree1 filename_or_URL

Author: Dodji Seketeli

tree2.c: Creates a tree

Shows how to create document, nodes and dump it to stdout or file.

Includes:

Uses:

Usage:

tree2 <filename> -Default output: stdout

Author: Lucas Brasilino <brasilino@recife.pe.gov.br>

XPath Examples

xpath1.c: Evaluate XPath expression and prints result node set.

Shows how to evaluate XPath expression and register known namespaces in XPath context.

Includes:

Uses:

Usage:

xpath1 <xml-file> <xpath-expr> [<known-ns-list>]

Author: Aleksey Sanin

xmlReader Examples

reader1.c: Parse an XML file with an xmlReader

Demonstrate the use of xmlReaderForFile() to parse an XML file and dump the informations about the nodes found in the process

Includes:

Uses:

Usage:

reader1 <filename>

Author: Daniel Veillard

reader2.c: Parse and validate an XML file with an xmlReader

Demonstrate the use of xmlReaderForFile() to parse an XML file validating the content in the process and activating options like entities substitution, and DTD attributes defaulting

Includes:

Uses:

Usage:

reader2 <valid_xml_filename>

Author: Daniel Veillard

reader3.c: Show how to extract subdocuments with xmlReader

Demonstrate the use of xmlTextReaderPreservePattern() to parse an XML file with the xmlReader while collecting only some subparts of the document

Includes:

Uses:

Usage:

reader3

Author: Daniel Veillard

xmlWriter Examples

testWriter.c: use various APIs for the xmlWriter

tests a number of APIs for the xmlWriter, especially the various methods to write to a filename, to a memory buffer, to a new document, or to a subtree. It shows how to do encoding string conversions too. The resulting documents are then serialized.

Includes:

Uses:

Usage:

testWriter

Author: Alfred Mickautsch

Daniel Veillard

diff --git a/doc/examples/reader3.c b/doc/examples/reader3.c new file mode 100644 index 00000000..715deeec --- /dev/null +++ b/doc/examples/reader3.c @@ -0,0 +1,104 @@ +/** + * section: xmlReader + * synopsis: Show how to extract subdocuments with xmlReader + * purpose: Demonstrate the use of xmlTextReaderPreservePattern() + * to parse an XML file with the xmlReader while collecting + * only some subparts of the document + * usage: reader3 + * test: reader3 > reader3.tmp ; diff reader3.tmp reader3.out ; rm reader3.tmp + * author: Daniel Veillard + * copy: see Copyright for the status of this software. + */ + +#include +#include + +/** + * streamFile: + * @filename: the file name to parse + * + * Parse and print information about an XML file. + * + * Returns the resulting doc with just the elements preserved. + */ +static xmlDocPtr +extractFile(const char *filename, const xmlChar *pattern) { + xmlDocPtr doc; + xmlTextReaderPtr reader; + int ret; + + /* + * build an xmlReader for that file + */ + reader = xmlReaderForFile(filename, NULL, 0); + if (reader != NULL) { + /* + * add the pattern to preserve + */ + if (xmlTextReaderPreservePattern(reader, pattern) < 0) { + fprintf(stderr, "%s : failed add preserve pattern %s\n", + filename, (const char *) pattern); + } + /* + * Parse and traverse the tree, collecting the nodes in the process + */ + ret = xmlTextReaderRead(reader); + while (ret == 1) { + ret = xmlTextReaderRead(reader); + } + if (ret != 0) { + fprintf(stderr, "%s : failed to parse\n", filename); + xmlFreeTextReader(reader); + return(NULL); + } + /* + * get the resulting nodes + */ + doc = xmlTextReaderCurrentDoc(reader); + /* + * Free up the reader + */ + xmlFreeTextReader(reader); + } else { + fprintf(stderr, "Unable to open %s\n", filename); + return(NULL); + } + return(doc); +} + +int main(int argc, char **argv) { + const char *filename = "test3.xml"; + const char *pattern = "preserved"; + xmlDocPtr doc; + + if (argc == 3) { + filename = argv[1]; + pattern = argv[2]; + } + + /* + * this initialize the library and check potential ABI mismatches + * between the version it was compiled for and the actual shared + * library used. + */ + LIBXML_TEST_VERSION + + doc = extractFile(filename, (const xmlChar *) pattern); + if (doc != NULL) { + /* + * ouptut the result. + */ + xmlDocDump(stdout, doc); + /* + * don't forget to free up the doc + */ + xmlFreeDoc(doc); + } + + + /* + * Cleanup function for the XML library. + */ + xmlCleanupParser(); + return(0); +} diff --git a/doc/examples/reader3.out b/doc/examples/reader3.out new file mode 100644 index 00000000..20e2e824 --- /dev/null +++ b/doc/examples/reader3.out @@ -0,0 +1,13 @@ + + + content1 + + content2 + too + content3 + + content4 + + content5 + content6 + diff --git a/doc/examples/test3.xml b/doc/examples/test3.xml new file mode 100644 index 00000000..4d0828f3 --- /dev/null +++ b/doc/examples/test3.xml @@ -0,0 +1,39 @@ + + + + + + + This text node must be discarded + + + + + content1 + + content2 + too + content3 + + content4 + + content5 + content6 + + This text node must be discarded + + + + This text node must be discarded + + This text node must be discarded + + This text node must be discarded + + + + This text node must be discarded + + + + diff --git a/doc/html/book1.html b/doc/html/book1.html index d3ffae24..49e03ca3 100644 --- a/doc/html/book1.html +++ b/doc/html/book1.html @@ -10,4 +10,4 @@ A:link, A:visited, A:active { text-decoration: underline } Reference Manual for libxml2
Action against software patentsGnome2 LogoW3C LogoRed Hat Logo
Made with Libxml2 Logo

Reference Manual for libxml2

API Menu
API Indexes
Related links

Table of Contents

  • DOCBparser: old DocBook SGML parser
  • HTMLparser: interface for an HTML 4.0 non-verifying parser
  • HTMLtree: specific APIs to process HTML tree, especially serialization
  • SAX: Old SAX version 1 handler, deprecated
  • SAX2: SAX2 parser interface used to build the DOM tree
  • c14n: Provide Canonical XML and Exclusive XML Canonicalization
  • catalog: interfaces to the Catalog handling system
  • chvalid: Unicode character range checking
  • debugXML: Tree debugging APIs
  • dict: string dictionnary
  • encoding: interface for the encoding conversion functions
  • entities: interface for the XML entities handling
  • globals: interface for all global variables of the library
  • hash: chained hash tables
  • list: lists interfaces
  • nanoftp: minimal FTP implementation
  • nanohttp: minimal HTTP implementation
  • parser: the core parser module
  • parserInternals: internals routines exported by the parser.
  • relaxng: implementation of the Relax-NG validation
  • schemasInternals: internal interfaces for XML Schemas
  • threads: interfaces for thread handling
  • tree: interfaces for tree manipulation
  • uri: library of generic URI related routines
  • valid: The DTD validation
  • xinclude: implementation of XInclude
  • xlink: unfinished XLink detection module
  • xmlIO: interface for the I/O interfaces used by the parser
  • xmlautomata: API to build regexp automata
  • xmlerror: error handling
  • xmlexports: macros for marking symbols as exportable/importable.
  • xmlmemory: interface for the memory allocator
  • xmlreader: the XMLReader implementation
  • xmlregexp: regular expressions handling
  • xmlschemas: incomplete XML Schemas structure implementation
  • xmlschemastypes: implementation of XML Schema Datatypes
  • xmlunicode: Unicode character APIs
  • xmlversion: compile-time version informations
  • xmlwriter: text writing API for XML
  • xpath: XML Path Language implementation
  • xpathInternals: internal interfaces for XML Path Language implementation
  • xpointer: API to handle XML Pointers

Daniel Veillard

+ Reference Manual for libxml2
Action against software patentsGnome2 LogoW3C LogoRed Hat Logo
Made with Libxml2 Logo

Reference Manual for libxml2

API Menu
API Indexes
Related links

Table of Contents

  • DOCBparser: old DocBook SGML parser
  • HTMLparser: interface for an HTML 4.0 non-verifying parser
  • HTMLtree: specific APIs to process HTML tree, especially serialization
  • SAX: Old SAX version 1 handler, deprecated
  • SAX2: SAX2 parser interface used to build the DOM tree
  • c14n: Provide Canonical XML and Exclusive XML Canonicalization
  • catalog: interfaces to the Catalog handling system
  • chvalid: Unicode character range checking
  • debugXML: Tree debugging APIs
  • dict: string dictionnary
  • encoding: interface for the encoding conversion functions
  • entities: interface for the XML entities handling
  • globals: interface for all global variables of the library
  • hash: chained hash tables
  • list: lists interfaces
  • nanoftp: minimal FTP implementation
  • nanohttp: minimal HTTP implementation
  • parser: the core parser module
  • parserInternals: internals routines exported by the parser.
  • pattern: pattern expression handling
  • relaxng: implementation of the Relax-NG validation
  • schemasInternals: internal interfaces for XML Schemas
  • threads: interfaces for thread handling
  • tree: interfaces for tree manipulation
  • uri: library of generic URI related routines
  • valid: The DTD validation
  • xinclude: implementation of XInclude
  • xlink: unfinished XLink detection module
  • xmlIO: interface for the I/O interfaces used by the parser
  • xmlautomata: API to build regexp automata
  • xmlerror: error handling
  • xmlexports: macros for marking symbols as exportable/importable.
  • xmlmemory: interface for the memory allocator
  • xmlreader: the XMLReader implementation
  • xmlregexp: regular expressions handling
  • xmlschemas: incomplete XML Schemas structure implementation
  • xmlschemastypes: implementation of XML Schema Datatypes
  • xmlunicode: Unicode character APIs
  • xmlversion: compile-time version informations
  • xmlwriter: text writing API for XML
  • xpath: XML Path Language implementation
  • xpathInternals: internal interfaces for XML Path Language implementation
  • xpointer: API to handle XML Pointers

Daniel Veillard

diff --git a/doc/html/index.html b/doc/html/index.html index d3ffae24..49e03ca3 100644 --- a/doc/html/index.html +++ b/doc/html/index.html @@ -10,4 +10,4 @@ A:link, A:visited, A:active { text-decoration: underline } Reference Manual for libxml2
Action against software patentsGnome2 LogoW3C LogoRed Hat Logo
Made with Libxml2 Logo

Reference Manual for libxml2

API Menu
API Indexes
Related links

Table of Contents

  • DOCBparser: old DocBook SGML parser
  • HTMLparser: interface for an HTML 4.0 non-verifying parser
  • HTMLtree: specific APIs to process HTML tree, especially serialization
  • SAX: Old SAX version 1 handler, deprecated
  • SAX2: SAX2 parser interface used to build the DOM tree
  • c14n: Provide Canonical XML and Exclusive XML Canonicalization
  • catalog: interfaces to the Catalog handling system
  • chvalid: Unicode character range checking
  • debugXML: Tree debugging APIs
  • dict: string dictionnary
  • encoding: interface for the encoding conversion functions
  • entities: interface for the XML entities handling
  • globals: interface for all global variables of the library
  • hash: chained hash tables
  • list: lists interfaces
  • nanoftp: minimal FTP implementation
  • nanohttp: minimal HTTP implementation
  • parser: the core parser module
  • parserInternals: internals routines exported by the parser.
  • relaxng: implementation of the Relax-NG validation
  • schemasInternals: internal interfaces for XML Schemas
  • threads: interfaces for thread handling
  • tree: interfaces for tree manipulation
  • uri: library of generic URI related routines
  • valid: The DTD validation
  • xinclude: implementation of XInclude
  • xlink: unfinished XLink detection module
  • xmlIO: interface for the I/O interfaces used by the parser
  • xmlautomata: API to build regexp automata
  • xmlerror: error handling
  • xmlexports: macros for marking symbols as exportable/importable.
  • xmlmemory: interface for the memory allocator
  • xmlreader: the XMLReader implementation
  • xmlregexp: regular expressions handling
  • xmlschemas: incomplete XML Schemas structure implementation
  • xmlschemastypes: implementation of XML Schema Datatypes
  • xmlunicode: Unicode character APIs
  • xmlversion: compile-time version informations
  • xmlwriter: text writing API for XML
  • xpath: XML Path Language implementation
  • xpathInternals: internal interfaces for XML Path Language implementation
  • xpointer: API to handle XML Pointers

Daniel Veillard

+ Reference Manual for libxml2
Action against software patentsGnome2 LogoW3C LogoRed Hat Logo
Made with Libxml2 Logo

Reference Manual for libxml2

API Menu
API Indexes
Related links

Table of Contents

  • DOCBparser: old DocBook SGML parser
  • HTMLparser: interface for an HTML 4.0 non-verifying parser
  • HTMLtree: specific APIs to process HTML tree, especially serialization
  • SAX: Old SAX version 1 handler, deprecated
  • SAX2: SAX2 parser interface used to build the DOM tree
  • c14n: Provide Canonical XML and Exclusive XML Canonicalization
  • catalog: interfaces to the Catalog handling system
  • chvalid: Unicode character range checking
  • debugXML: Tree debugging APIs
  • dict: string dictionnary
  • encoding: interface for the encoding conversion functions
  • entities: interface for the XML entities handling
  • globals: interface for all global variables of the library
  • hash: chained hash tables
  • list: lists interfaces
  • nanoftp: minimal FTP implementation
  • nanohttp: minimal HTTP implementation
  • parser: the core parser module
  • parserInternals: internals routines exported by the parser.
  • pattern: pattern expression handling
  • relaxng: implementation of the Relax-NG validation
  • schemasInternals: internal interfaces for XML Schemas
  • threads: interfaces for thread handling
  • tree: interfaces for tree manipulation
  • uri: library of generic URI related routines
  • valid: The DTD validation
  • xinclude: implementation of XInclude
  • xlink: unfinished XLink detection module
  • xmlIO: interface for the I/O interfaces used by the parser
  • xmlautomata: API to build regexp automata
  • xmlerror: error handling
  • xmlexports: macros for marking symbols as exportable/importable.
  • xmlmemory: interface for the memory allocator
  • xmlreader: the XMLReader implementation
  • xmlregexp: regular expressions handling
  • xmlschemas: incomplete XML Schemas structure implementation
  • xmlschemastypes: implementation of XML Schema Datatypes
  • xmlunicode: Unicode character APIs
  • xmlversion: compile-time version informations
  • xmlwriter: text writing API for XML
  • xpath: XML Path Language implementation
  • xpathInternals: internal interfaces for XML Path Language implementation
  • xpointer: API to handle XML Pointers

Daniel Veillard

diff --git a/doc/html/libxml-lib.html b/doc/html/libxml-lib.html index d3ffae24..49e03ca3 100644 --- a/doc/html/libxml-lib.html +++ b/doc/html/libxml-lib.html @@ -10,4 +10,4 @@ A:link, A:visited, A:active { text-decoration: underline } Reference Manual for libxml2
Action against software patentsGnome2 LogoW3C LogoRed Hat Logo
Made with Libxml2 Logo

Reference Manual for libxml2

API Menu
API Indexes
Related links

Table of Contents

  • DOCBparser: old DocBook SGML parser
  • HTMLparser: interface for an HTML 4.0 non-verifying parser
  • HTMLtree: specific APIs to process HTML tree, especially serialization
  • SAX: Old SAX version 1 handler, deprecated
  • SAX2: SAX2 parser interface used to build the DOM tree
  • c14n: Provide Canonical XML and Exclusive XML Canonicalization
  • catalog: interfaces to the Catalog handling system
  • chvalid: Unicode character range checking
  • debugXML: Tree debugging APIs
  • dict: string dictionnary
  • encoding: interface for the encoding conversion functions
  • entities: interface for the XML entities handling
  • globals: interface for all global variables of the library
  • hash: chained hash tables
  • list: lists interfaces
  • nanoftp: minimal FTP implementation
  • nanohttp: minimal HTTP implementation
  • parser: the core parser module
  • parserInternals: internals routines exported by the parser.
  • relaxng: implementation of the Relax-NG validation
  • schemasInternals: internal interfaces for XML Schemas
  • threads: interfaces for thread handling
  • tree: interfaces for tree manipulation
  • uri: library of generic URI related routines
  • valid: The DTD validation
  • xinclude: implementation of XInclude
  • xlink: unfinished XLink detection module
  • xmlIO: interface for the I/O interfaces used by the parser
  • xmlautomata: API to build regexp automata
  • xmlerror: error handling
  • xmlexports: macros for marking symbols as exportable/importable.
  • xmlmemory: interface for the memory allocator
  • xmlreader: the XMLReader implementation
  • xmlregexp: regular expressions handling
  • xmlschemas: incomplete XML Schemas structure implementation
  • xmlschemastypes: implementation of XML Schema Datatypes
  • xmlunicode: Unicode character APIs
  • xmlversion: compile-time version informations
  • xmlwriter: text writing API for XML
  • xpath: XML Path Language implementation
  • xpathInternals: internal interfaces for XML Path Language implementation
  • xpointer: API to handle XML Pointers

Daniel Veillard

+ Reference Manual for libxml2
Action against software patentsGnome2 LogoW3C LogoRed Hat Logo
Made with Libxml2 Logo

Reference Manual for libxml2

API Menu
API Indexes
Related links

Table of Contents

  • DOCBparser: old DocBook SGML parser
  • HTMLparser: interface for an HTML 4.0 non-verifying parser
  • HTMLtree: specific APIs to process HTML tree, especially serialization
  • SAX: Old SAX version 1 handler, deprecated
  • SAX2: SAX2 parser interface used to build the DOM tree
  • c14n: Provide Canonical XML and Exclusive XML Canonicalization
  • catalog: interfaces to the Catalog handling system
  • chvalid: Unicode character range checking
  • debugXML: Tree debugging APIs
  • dict: string dictionnary
  • encoding: interface for the encoding conversion functions
  • entities: interface for the XML entities handling
  • globals: interface for all global variables of the library
  • hash: chained hash tables
  • list: lists interfaces
  • nanoftp: minimal FTP implementation
  • nanohttp: minimal HTTP implementation
  • parser: the core parser module
  • parserInternals: internals routines exported by the parser.
  • pattern: pattern expression handling
  • relaxng: implementation of the Relax-NG validation
  • schemasInternals: internal interfaces for XML Schemas
  • threads: interfaces for thread handling
  • tree: interfaces for tree manipulation
  • uri: library of generic URI related routines
  • valid: The DTD validation
  • xinclude: implementation of XInclude
  • xlink: unfinished XLink detection module
  • xmlIO: interface for the I/O interfaces used by the parser
  • xmlautomata: API to build regexp automata
  • xmlerror: error handling
  • xmlexports: macros for marking symbols as exportable/importable.
  • xmlmemory: interface for the memory allocator
  • xmlreader: the XMLReader implementation
  • xmlregexp: regular expressions handling
  • xmlschemas: incomplete XML Schemas structure implementation
  • xmlschemastypes: implementation of XML Schema Datatypes
  • xmlunicode: Unicode character APIs
  • xmlversion: compile-time version informations
  • xmlwriter: text writing API for XML
  • xpath: XML Path Language implementation
  • xpathInternals: internal interfaces for XML Path Language implementation
  • xpointer: API to handle XML Pointers

Daniel Veillard

diff --git a/doc/html/libxml-parserInternals.html b/doc/html/libxml-parserInternals.html index bcdac4cf..2cfb2803 100644 --- a/doc/html/libxml-parserInternals.html +++ b/doc/html/libxml-parserInternals.html @@ -10,7 +10,7 @@ A:link, A:visited, A:active { text-decoration: underline } Module parserInternals from libxml2
Action against software patentsGnome2 LogoW3C LogoRed Hat Logo
Made with Libxml2 Logo

Module parserInternals from libxml2

API Menu
API Indexes
Related links

this module exports a number of internal parsing routines they are not really all intended for applications but can prove useful doing low level processing.

Table of Contents

#define INPUT_CHUNK
#define IS_BASECHAR
#define IS_BLANK
#define IS_BLANK_CH
#define IS_BYTE_CHAR
#define IS_CHAR
#define IS_CHAR_CH
#define IS_COMBINING
#define IS_COMBINING_CH
#define IS_DIGIT
#define IS_DIGIT_CH
#define IS_EXTENDER
#define IS_EXTENDER_CH
#define IS_IDEOGRAPHIC
#define IS_LETTER
#define IS_LETTER_CH
#define IS_PUBIDCHAR
#define IS_PUBIDCHAR_CH
#define MOVETO_ENDTAG
#define MOVETO_STARTTAG
#define SKIP_EOL
#define XML_MAX_NAMELEN
#define XML_SUBSTITUTE_BOTH
#define XML_SUBSTITUTE_NONE
#define XML_SUBSTITUTE_PEREF
#define XML_SUBSTITUTE_REF
htmlParserCtxtPtr	htmlCreateFileParserCtxt	(const char * filename, 
const char * encoding)
+ Module parserInternals from libxml2
Action against software patentsGnome2 LogoW3C LogoRed Hat Logo
Made with Libxml2 Logo

Module parserInternals from libxml2

API Menu
API Indexes
Related links

this module exports a number of internal parsing routines they are not really all intended for applications but can prove useful doing low level processing.

Table of Contents

#define INPUT_CHUNK
#define IS_BASECHAR
#define IS_BLANK
#define IS_BLANK_CH
#define IS_BYTE_CHAR
#define IS_CHAR
#define IS_CHAR_CH
#define IS_COMBINING
#define IS_COMBINING_CH
#define IS_DIGIT
#define IS_DIGIT_CH
#define IS_EXTENDER
#define IS_EXTENDER_CH
#define IS_IDEOGRAPHIC
#define IS_LETTER
#define IS_LETTER_CH
#define IS_PUBIDCHAR
#define IS_PUBIDCHAR_CH
#define MOVETO_ENDTAG
#define MOVETO_STARTTAG
#define SKIP_EOL
#define XML_MAX_NAMELEN
#define XML_SUBSTITUTE_BOTH
#define XML_SUBSTITUTE_NONE
#define XML_SUBSTITUTE_PEREF
#define XML_SUBSTITUTE_REF
htmlParserCtxtPtr	htmlCreateFileParserCtxt	(const char * filename, 
const char * encoding)
void	htmlInitAutoClose		(void)
xmlParserInputPtr	inputPop	(xmlParserCtxtPtr ctxt)
int	inputPush			(xmlParserCtxtPtr ctxt, 
xmlParserInputPtr value)
diff --git a/doc/html/libxml-relaxng.html b/doc/html/libxml-relaxng.html index 842d1cd8..cf3d5915 100644 --- a/doc/html/libxml-relaxng.html +++ b/doc/html/libxml-relaxng.html @@ -10,7 +10,7 @@ A:link, A:visited, A:active { text-decoration: underline } Module relaxng from libxml2
Action against software patentsGnome2 LogoW3C LogoRed Hat Logo
Made with Libxml2 Logo

Module relaxng from libxml2

API Menu
API Indexes
Related links

implementation of the Relax-NG validation

Table of Contents

Structure xmlRelaxNG
struct _xmlRelaxNG + Module relaxng from libxml2
Action against software patentsGnome2 LogoW3C LogoRed Hat Logo
Made with Libxml2 Logo

Module relaxng from libxml2

API Menu
API Indexes
Related links

implementation of the Relax-NG validation

Table of Contents

Structure xmlRelaxNG
struct _xmlRelaxNG The content of this structure is not made public by the API.
Structure xmlRelaxNGParserCtxt
struct _xmlRelaxNGParserCtxt The content of this structure is not made public by the API. diff --git a/doc/html/libxml-schemasInternals.html b/doc/html/libxml-schemasInternals.html index 63405c1b..f8b7bc0a 100644 --- a/doc/html/libxml-schemasInternals.html +++ b/doc/html/libxml-schemasInternals.html @@ -31,9 +31,9 @@ The content of this structure is not made public by the API.
Typedef xmlSchemaVal * xmlSchemaValPtr
 
void	xmlSchemaFreeType		(xmlSchemaTypePtr type)

Description

-

Macro: XML_SCHEMAS_ANYATTR_LAX

#define XML_SCHEMAS_ANYATTR_LAX

-

Macro: XML_SCHEMAS_ANYATTR_SKIP

#define XML_SCHEMAS_ANYATTR_SKIP

-

Macro: XML_SCHEMAS_ANYATTR_STRICT

#define XML_SCHEMAS_ANYATTR_STRICT

+

Macro: XML_SCHEMAS_ANYATTR_LAX

#define XML_SCHEMAS_ANYATTR_LAX

Ignore validation non definition on attributes

+

Macro: XML_SCHEMAS_ANYATTR_SKIP

#define XML_SCHEMAS_ANYATTR_SKIP

Skip unknown attribute from validation

+

Macro: XML_SCHEMAS_ANYATTR_STRICT

#define XML_SCHEMAS_ANYATTR_STRICT

Apply strict validation rules on attributes

Macro: XML_SCHEMAS_ATTR_NSDEFAULT

#define XML_SCHEMAS_ATTR_NSDEFAULT

allow elements in no namespace

Macro: XML_SCHEMAS_ELEM_ABSTRACT

#define XML_SCHEMAS_ELEM_ABSTRACT

the element is abstract

Macro: XML_SCHEMAS_ELEM_DEFAULT

#define XML_SCHEMAS_ELEM_DEFAULT

the element has a default value

diff --git a/doc/html/libxml-xmlexports.html b/doc/html/libxml-xmlexports.html index d6f2806b..69843c90 100644 --- a/doc/html/libxml-xmlexports.html +++ b/doc/html/libxml-xmlexports.html @@ -12,7 +12,7 @@ A:link, A:visited, A:active { text-decoration: underline } pre.programlisting {border-style: double} Module xmlexports from libxml2
Action against software patentsGnome2 LogoW3C LogoRed Hat Logo
Made with Libxml2 Logo

Module xmlexports from libxml2

API Menu
API Indexes
Related links

macros for marking symbols as exportable/importable.

Table of Contents

#define LIBXML_DLL_IMPORT
#define XMLCALL
#define XMLPUBFUN
#define XMLPUBVAR
#define _REENTRANT

Description

Macro: LIBXML_DLL_IMPORT

#define LIBXML_DLL_IMPORT

-

Macro: XMLCALL

#define XMLCALL

Macros which declare the called convention for exported functions Windows platform with MS compiler Windows platform with Borland compiler Windows platform with GNU compiler (Mingw) Cygwin platform, GNU compiler

+

Macro: XMLCALL

#define XMLCALL

Macro: XMLPUBFUN

#define XMLPUBFUN

Macro: XMLPUBVAR

#define XMLPUBVAR

Macro: _REENTRANT

#define _REENTRANT

diff --git a/doc/html/libxml-xmlreader.html b/doc/html/libxml-xmlreader.html index ed0874fd..083cd33e 100644 --- a/doc/html/libxml-xmlreader.html +++ b/doc/html/libxml-xmlreader.html @@ -79,6 +79,7 @@ void xmlTextReaderErrorFunc (void * arg,
int	xmlTextReaderNormalization	(xmlTextReaderPtr reader)
xmlChar *	xmlTextReaderPrefix	(xmlTextReaderPtr reader)
xmlNodePtr	xmlTextReaderPreserve	(xmlTextReaderPtr reader)
+
int	xmlTextReaderPreservePattern	(xmlTextReaderPtr reader, 
const xmlChar * pattern)
int	xmlTextReaderQuoteChar		(xmlTextReaderPtr reader)
int	xmlTextReaderRead		(xmlTextReaderPtr reader)
int	xmlTextReaderReadAttributeValue	(xmlTextReaderPtr reader)
@@ -248,7 +249,9 @@ void xmlTextReaderErrorFunc (void * arg,
const char * msg,

A shorthand reference to the namespace associated with the node.

reader:the xmlTextReaderPtr used
Returns:the prefix or NULL if not available

Function: xmlTextReaderPreserve

xmlNodePtr	xmlTextReaderPreserve	(xmlTextReaderPtr reader)

current node being accessed by the xmlTextReader. This is dangerous because the underlying node may be destroyed on the next Reads.

-
reader:the xmlTextReaderPtr used
Returns:the xmlNodePtr or NULL in case of error.

Function: xmlTextReaderQuoteChar

int	xmlTextReaderQuoteChar		(xmlTextReaderPtr reader)
+
reader:the xmlTextReaderPtr used
Returns:the xmlNodePtr or NULL in case of error.

Function: xmlTextReaderPreservePattern

int	xmlTextReaderPreservePattern	(xmlTextReaderPtr reader, 
const xmlChar * pattern)
+

This tells the XML Reader to preserve all nodes matched by the pattern. The caller must also use xmlTextReaderCurrentDoc() to keep an handle on the resulting document once parsing has finished

+
reader:the xmlTextReaderPtr used
pattern:an XPath subset pattern
Returns:a positive number in case of success and -1 in case of error

Function: xmlTextReaderQuoteChar

int	xmlTextReaderQuoteChar		(xmlTextReaderPtr reader)

The quotation mark character used to enclose the value of an attribute.

reader:the xmlTextReaderPtr used
Returns:" or ' and -1 in case of error

Function: xmlTextReaderRead

int	xmlTextReaderRead		(xmlTextReaderPtr reader)

Moves the position of the current instance to the next node in the stream, exposing its properties.

diff --git a/doc/html/libxml-xmlversion.html b/doc/html/libxml-xmlversion.html index 6ba1c0ae..ec1fc950 100644 --- a/doc/html/libxml-xmlversion.html +++ b/doc/html/libxml-xmlversion.html @@ -27,7 +27,7 @@ A:link, A:visited, A:active { text-decoration: underline }

Macro: LIBXML_ISO8859X_ENABLED

#define LIBXML_ISO8859X_ENABLED

Whether ISO-8859-* support is made available in case iconv is not

Macro: LIBXML_LEGACY_ENABLED

#define LIBXML_LEGACY_ENABLED

Whether the deprecated APIs are compiled in for compatibility

Macro: LIBXML_OUTPUT_ENABLED

#define LIBXML_OUTPUT_ENABLED

Whether the serialization/saving support is configured in

-

Macro: LIBXML_PATTERN_ENABLED

#define LIBXML_PATTERN_ENABLED

Whether the xmlPattern node selection interface is configured in

+

Macro: LIBXML_PATTERN_ENABLED

#define LIBXML_PATTERN_ENABLED

Whether the xmlPattern node selection interface is configured in

Macro: LIBXML_PUSH_ENABLED

#define LIBXML_PUSH_ENABLED

Whether the push parsing interfaces are configured in

Macro: LIBXML_READER_ENABLED

#define LIBXML_READER_ENABLED

Whether the xmlReader parsing interface is configured in

Macro: LIBXML_REGEXP_ENABLED

#define LIBXML_REGEXP_ENABLED

Whether the regular expressions interfaces are compiled in

diff --git a/doc/html/libxml-xmlwriter.html b/doc/html/libxml-xmlwriter.html index 9f9b997d..d02e96d7 100644 --- a/doc/html/libxml-xmlwriter.html +++ b/doc/html/libxml-xmlwriter.html @@ -85,11 +85,11 @@ The content of this structure is not made public by the API.
int	xmlTextWriterWriteVFormatRaw	(xmlTextWriterPtr writer, 
const char * format,
va_list argptr)
int	xmlTextWriterWriteVFormatString	(xmlTextWriterPtr writer, 
const char * format,
va_list argptr)

Description

-

Macro: xmlTextWriterEndDTDAttlist

#define xmlTextWriterEndDTDAttlist

-

Macro: xmlTextWriterEndDTDElement

#define xmlTextWriterEndDTDElement

-

Macro: xmlTextWriterEndDTDEntity

#define xmlTextWriterEndDTDEntity

-

Macro: xmlTextWriterWriteDocType

#define xmlTextWriterWriteDocType

-

Macro: xmlTextWriterWriteProcessingInstruction

#define xmlTextWriterWriteProcessingInstruction

+

Macro: xmlTextWriterEndDTDAttlist

#define xmlTextWriterEndDTDAttlist

This macro maps to xmlTextWriterEndDTD

+

Macro: xmlTextWriterEndDTDElement

#define xmlTextWriterEndDTDElement

This macro maps to xmlTextWriterEndDTD

+

Macro: xmlTextWriterEndDTDEntity

#define xmlTextWriterEndDTDEntity

This macro maps to xmlTextWriterEndDTD

+

Macro: xmlTextWriterWriteDocType

#define xmlTextWriterWriteDocType

this macro maps to xmlTextWriterWriteDTD

+

Macro: xmlTextWriterWriteProcessingInstruction

#define xmlTextWriterWriteProcessingInstruction

This macro maps to xmlTextWriterWritePI

Structure xmlTextWriter

Structure xmlTextWriter
struct _xmlTextWriter { The content of this structure is not made public by the API. }

Function: xmlFreeTextWriter

void	xmlFreeTextWriter		(xmlTextWriterPtr writer)
@@ -205,8 +205,8 @@ The content of this structure is not made public by the API.
writer:the xmlTextWriterPtr
target:PI target
content:PI content
Returns:the bytes written (may be 0 because of buffering) or -1 in case of error

Function: xmlTextWriterWriteRaw

int	xmlTextWriterWriteRaw		(xmlTextWriterPtr writer, 
const xmlChar * content)

Write a raw xml text.

writer:the xmlTextWriterPtr
content:text string
Returns:the bytes written (may be 0 because of buffering) or -1 in case of error

Function: xmlTextWriterWriteRawLen

int	xmlTextWriterWriteRawLen	(xmlTextWriterPtr writer, 
const xmlChar * content,
int len)
-

-
writer:
content:
len:
Returns:

Function: xmlTextWriterWriteString

int	xmlTextWriterWriteString	(xmlTextWriterPtr writer, 
const xmlChar * content)
+

Write an xml text. TODO: what about entities and special chars??

+
writer:the xmlTextWriterPtr
content:text string
len:length of the text string
Returns:the bytes written (may be 0 because of buffering) or -1 in case of error

Function: xmlTextWriterWriteString

int	xmlTextWriterWriteString	(xmlTextWriterPtr writer, 
const xmlChar * content)

Write an xml text.

writer:the xmlTextWriterPtr
content:text string
Returns:the bytes written (may be 0 because of buffering) or -1 in case of error

Function: xmlTextWriterWriteVFormatAttribute

int	xmlTextWriterWriteVFormatAttribute	(xmlTextWriterPtr writer, 
const xmlChar * name,
const char * format,
va_list argptr)

Write a formatted xml attribute.

diff --git a/doc/libxml2-api.xml b/doc/libxml2-api.xml index 55a160b6..274a445d 100644 --- a/doc/libxml2-api.xml +++ b/doc/libxml2-api.xml @@ -953,6 +953,17 @@ + + pattern expression handling + allows to compile and test pattern expressions for nodes either in a tree or based on a parser state. + Daniel Veillard + + + + + + + implementation of the Relax-NG validation implementation of the Relax-NG validation @@ -2337,6 +2348,7 @@ + @@ -3293,7 +3305,6 @@ Macro defining "xml" - Macros which declare the called convention for exported functions Windows platform with MS compiler Windows platform with Borland compiler Windows platform with GNU compiler (Mingw) Cygwin platform, GNU compiler @@ -3330,10 +3341,13 @@ Special constant found in SAX2 blocks initialized fields + Ignore validation non definition on attributes + Skip unknown attribute from validation + Apply strict validation rules on attributes allow elements in no namespace @@ -3487,14 +3501,19 @@ Macro for compatibility naming layer with libxml1. + This macro maps to xmlTextWriterEndDTD + This macro maps to xmlTextWriterEndDTD + This macro maps to xmlTextWriterEndDTD + this macro maps to xmlTextWriterWriteDTD + This macro maps to xmlTextWriterWritePI Check if an XPath error was raised. Returns true if an error has been raised, false otherwise. @@ -4935,6 +4954,8 @@ actually an xmlCharEncoding'/> + + @@ -7771,6 +7792,16 @@ actually an xmlCharEncoding'/> + + Free up the memory allocated by @comp + + + + + Free up the memory allocated by all the elements of @comp + + + Free one attribute, all the content is freed too @@ -9986,6 +10017,19 @@ actually an xmlCharEncoding'/> + + Test wether the node matches the pattern + + + + + + Compile a pattern + + + + + Set and return the previous value for enabling pedantic warnings. @@ -11715,6 +11759,12 @@ actually an xmlCharEncoding'/> + + This tells the XML Reader to preserve all nodes matched by the pattern. The caller must also use xmlTextReaderCurrentDoc() to keep an handle on the resulting document once parsing has finished + + + + The quotation mark character used to enclose the value of an attribute. @@ -12141,11 +12191,11 @@ actually an xmlCharEncoding'/> - - - - - + Write an xml text. TODO: what about entities and special chars?? + + + + Write an xml text. diff --git a/doc/libxml2-refs.xml b/doc/libxml2-refs.xml index a929a7c8..1088559a 100644 --- a/doc/libxml2-refs.xml +++ b/doc/libxml2-refs.xml @@ -1473,6 +1473,8 @@ + + @@ -1928,6 +1930,10 @@ + + + + @@ -2264,6 +2270,7 @@ + @@ -4346,6 +4353,8 @@ + + @@ -4801,6 +4810,10 @@ + + + + @@ -5137,6 +5150,7 @@ + @@ -5693,38 +5707,38 @@ + - - + - + - + - + - + - + @@ -5739,8 +5753,8 @@ - + @@ -5753,8 +5767,8 @@ + - @@ -5763,21 +5777,21 @@ + - - + - - + + @@ -5788,28 +5802,28 @@ - - - + + + - - + + @@ -5817,8 +5831,8 @@ + - @@ -5832,15 +5846,15 @@ + - - + @@ -5857,9 +5871,9 @@ + - @@ -5893,53 +5907,52 @@ + - + - + + - - - - + - - + + + + - - @@ -5947,26 +5960,27 @@ + - + - - + + + - @@ -5994,7 +6008,7 @@ - + @@ -6003,25 +6017,25 @@ + + - - + - @@ -6047,17 +6061,17 @@ + - + - @@ -6066,8 +6080,8 @@ - + @@ -6092,22 +6106,21 @@ - + - + - @@ -6123,31 +6136,32 @@ + + - - - - - - - - + + + + + - + + + @@ -6165,8 +6179,8 @@ - + @@ -6178,8 +6192,8 @@ - + @@ -6190,20 +6204,20 @@ - + - + + - @@ -6217,11 +6231,11 @@ + - @@ -6230,6 +6244,9 @@ + + + @@ -6249,8 +6266,8 @@ - + @@ -6277,17 +6294,17 @@ - - - + + + - + @@ -6320,12 +6337,10 @@ - - - - + + @@ -6333,23 +6348,25 @@ - + + + + - - + - + @@ -6796,6 +6813,7 @@ + @@ -6907,6 +6925,7 @@ + @@ -7722,6 +7741,9 @@ + + + @@ -8173,6 +8195,7 @@ + @@ -8510,6 +8533,11 @@ + + + + + @@ -8755,6 +8783,7 @@ + @@ -9907,6 +9936,14 @@ + + + + + + + + @@ -11199,14 +11236,14 @@ - + - + @@ -11230,6 +11267,7 @@ + @@ -11262,7 +11300,7 @@ - + @@ -12062,6 +12100,9 @@ + + + @@ -12230,9 +12271,6 @@ - - - @@ -12575,6 +12613,7 @@ + @@ -12707,9 +12746,6 @@ - - - @@ -13391,9 +13427,6 @@ - - - @@ -13650,6 +13683,9 @@ + + + @@ -13922,9 +13958,6 @@ - - - @@ -13972,9 +14005,6 @@ - - - @@ -14667,6 +14697,9 @@ + + + @@ -15139,6 +15172,7 @@ + @@ -15285,6 +15319,7 @@ + @@ -15329,6 +15364,9 @@ + + + @@ -15703,9 +15741,6 @@ - - - @@ -15862,6 +15897,8 @@ + + @@ -15944,6 +15981,7 @@ + @@ -16291,6 +16329,7 @@ + @@ -17166,6 +17205,9 @@ + + + @@ -17416,6 +17458,8 @@ + + @@ -17464,8 +17508,12 @@ + + + + @@ -17493,6 +17541,7 @@ + @@ -17508,9 +17557,6 @@ - - - @@ -17816,9 +17862,6 @@ - - - @@ -18109,7 +18152,6 @@ - @@ -18420,6 +18462,7 @@ + @@ -18606,6 +18649,7 @@ + @@ -18772,6 +18816,7 @@ + @@ -19167,9 +19212,6 @@ - - - @@ -19311,6 +19353,7 @@ + @@ -19437,6 +19480,7 @@ + @@ -19468,6 +19512,7 @@ + @@ -19673,7 +19718,6 @@ - @@ -19897,6 +19941,7 @@ + @@ -20653,6 +20698,7 @@ + @@ -20777,6 +20823,7 @@ + @@ -21246,6 +21293,13 @@ + + + + + + + @@ -21311,6 +21365,11 @@ + + + + + @@ -21347,6 +21406,9 @@ + + + @@ -21355,6 +21417,7 @@ + @@ -21812,6 +21875,7 @@ + @@ -22113,6 +22177,7 @@ + @@ -22225,6 +22290,7 @@ + @@ -22483,6 +22549,11 @@ + + + + + @@ -22532,9 +22603,6 @@ - - - @@ -22609,6 +22677,7 @@ + @@ -22678,6 +22747,7 @@ + @@ -22746,6 +22816,7 @@ + @@ -23849,6 +23920,7 @@ + @@ -24417,6 +24489,7 @@ + @@ -24680,6 +24753,7 @@ + @@ -24699,6 +24773,7 @@ + @@ -25000,6 +25075,9 @@ + + + @@ -25486,6 +25564,9 @@ + + + @@ -25533,6 +25614,7 @@ + @@ -25882,12 +25964,14 @@ + + @@ -26793,6 +26877,9 @@ + + + @@ -26800,6 +26887,17 @@ + + + + + + + + + + + @@ -26949,6 +27047,9 @@ + + + diff --git a/globals.c b/globals.c index 8de87e4b..69b4dc20 100644 --- a/globals.c +++ b/globals.c @@ -540,6 +540,10 @@ xmlInitializeGlobalState(xmlGlobalStatePtr gs) xmlMutexUnlock(xmlThrDefMutex); } +/** + * DOC_DISABLE : we ignore missing doc for the xmlThrDef functions, + * those are really internal work + */ void xmlThrDefSetGenericErrorFunc(void *ctx, xmlGenericErrorFunc handler) { xmlMutexLock(xmlThrDefMutex); diff --git a/include/libxml/globals.h b/include/libxml/globals.h index e38c1032..1be2d1fe 100644 --- a/include/libxml/globals.h +++ b/include/libxml/globals.h @@ -131,6 +131,7 @@ XMLPUBFUN xmlRegisterNodeFunc XMLCALL xmlThrDefRegisterNodeDefault(xmlRegisterNo XMLPUBFUN xmlDeregisterNodeFunc XMLCALL xmlDeregisterNodeDefault(xmlDeregisterNodeFunc func); XMLPUBFUN xmlDeregisterNodeFunc XMLCALL xmlThrDefDeregisterNodeDefault(xmlDeregisterNodeFunc func); +/** DOC_DISABLE */ /* * In general the memory allocation entry points are not kept * thread specific but this can be overridden by LIBXML_THREAD_ALLOC_ENABLED diff --git a/include/libxml/pattern.h b/include/libxml/pattern.h index 6aa7de17..bac6b4ef 100644 --- a/include/libxml/pattern.h +++ b/include/libxml/pattern.h @@ -35,7 +35,7 @@ XMLPUBFUN void XMLCALL XMLPUBFUN xmlPatternPtr XMLCALL xmlPatterncompile (const xmlChar *pattern, - xmlDict *dictionnary, + xmlDict *dict, int flags); XMLPUBFUN int XMLCALL xmlPatternMatch (xmlPatternPtr comp, diff --git a/include/libxml/schemasInternals.h b/include/libxml/schemasInternals.h index 10490c4f..d7925870 100644 --- a/include/libxml/schemasInternals.h +++ b/include/libxml/schemasInternals.h @@ -94,11 +94,22 @@ struct _xmlSchemaAnnot { }; /** - * An attribute definition. + * XML_SCHEMAS_ANYATTR_SKIP: + * + * Skip unknown attribute from validation */ - #define XML_SCHEMAS_ANYATTR_SKIP 1 +/** + * XML_SCHEMAS_ANYATTR_LAX: + * + * Ignore validation non definition on attributes + */ #define XML_SCHEMAS_ANYATTR_LAX 2 +/** + * XML_SCHEMAS_ANYATTR_STRICT: + * + * Apply strict validation rules on attributes + */ #define XML_SCHEMAS_ANYATTR_STRICT 3 /** @@ -108,6 +119,11 @@ struct _xmlSchemaAnnot { */ #define XML_SCHEMAS_ATTR_NSDEFAULT 1 << 7 +/** + * xmlSchemaAttribute: + * An attribute definition. + */ + typedef struct _xmlSchemaAttribute xmlSchemaAttribute; typedef xmlSchemaAttribute *xmlSchemaAttributePtr; struct _xmlSchemaAttribute { diff --git a/include/libxml/xmlexports.h b/include/libxml/xmlexports.h index c90e4207..8d6791d5 100644 --- a/include/libxml/xmlexports.h +++ b/include/libxml/xmlexports.h @@ -41,6 +41,8 @@ */ #define XMLCALL +/** DOC_DISABLE */ + /* Windows platform with MS compiler */ #if defined(_WIN32) && defined(_MSC_VER) #undef XMLPUBFUN diff --git a/include/libxml/xmlreader.h b/include/libxml/xmlreader.h index a144764f..c9c79899 100644 --- a/include/libxml/xmlreader.h +++ b/include/libxml/xmlreader.h @@ -196,6 +196,9 @@ XMLPUBFUN xmlNodePtr XMLCALL xmlTextReaderCurrentNode (xmlTextReaderPtr reader); XMLPUBFUN xmlNodePtr XMLCALL xmlTextReaderPreserve (xmlTextReaderPtr reader); +XMLPUBFUN int XMLCALL + xmlTextReaderPreservePattern(xmlTextReaderPtr reader, + const xmlChar *pattern); XMLPUBFUN xmlDocPtr XMLCALL xmlTextReaderCurrentDoc (xmlTextReaderPtr reader); XMLPUBFUN xmlNodePtr XMLCALL diff --git a/include/libxml/xmlwriter.h b/include/libxml/xmlwriter.h index e35e76a8..5aeafa21 100644 --- a/include/libxml/xmlwriter.h +++ b/include/libxml/xmlwriter.h @@ -225,6 +225,11 @@ XMLPUBFUN int XMLCALL xmlTextWriterWritePI (xmlTextWriterPtr writer, const xmlChar * target, const xmlChar * content); +/** + * xmlTextWriterWriteProcessingInstruction: + * + * This macro maps to xmlTextWriterWritePI + */ #define xmlTextWriterWriteProcessingInstruction xmlTextWriterWritePI /* @@ -277,6 +282,11 @@ XMLPUBFUN int XMLCALL const xmlChar * pubid, const xmlChar * sysid, const xmlChar * subset); +/** + * xmlTextWriterWriteDocType: + * + * this macro maps to xmlTextWriterWriteDTD + */ #define xmlTextWriterWriteDocType xmlTextWriterWriteDTD /* @@ -285,6 +295,11 @@ XMLPUBFUN int XMLCALL XMLPUBFUN int XMLCALL xmlTextWriterStartDTDElement (xmlTextWriterPtr writer, const xmlChar * name); +/** + * xmlTextWriterEndDTDElement: + * + * This macro maps to xmlTextWriterEndDTD + */ #define xmlTextWriterEndDTDElement xmlTextWriterEndDTD /* @@ -310,6 +325,11 @@ XMLPUBFUN int XMLCALL XMLPUBFUN int XMLCALL xmlTextWriterStartDTDAttlist (xmlTextWriterPtr writer, const xmlChar * name); +/** + * xmlTextWriterEndDTDAttlist: + * + * This macro maps to xmlTextWriterEndDTD + */ #define xmlTextWriterEndDTDAttlist xmlTextWriterEndDTD /* @@ -335,6 +355,11 @@ XMLPUBFUN int XMLCALL XMLPUBFUN int XMLCALL xmlTextWriterStartDTDEntity (xmlTextWriterPtr writer, int pe, const xmlChar * name); +/** + * xmlTextWriterEndDTDEntity: + * + * This macro maps to xmlTextWriterEndDTD + */ #define xmlTextWriterEndDTDEntity xmlTextWriterEndDTD /* diff --git a/pattern.c b/pattern.c index e0f1566a..01f974c3 100644 --- a/pattern.c +++ b/pattern.c @@ -877,11 +877,11 @@ error: * Returns the compiled for of the pattern or NULL in case of error */ xmlPatternPtr -xmlPatterncompile(const xmlChar *pattern, xmlDict *dictionnary, int flags) { +xmlPatterncompile(const xmlChar *pattern, xmlDict *dict, int flags) { xmlPatternPtr ret = NULL; xmlPatParserContextPtr ctxt = NULL; - ctxt = xmlNewPatParserContext(pattern, dictionnary); + ctxt = xmlNewPatParserContext(pattern, dict); if (ctxt == NULL) goto error; ret = xmlNewPattern(); if (ret == NULL) goto error; diff --git a/python/libxml2class.txt b/python/libxml2class.txt index 271dbebc..b73910b5 100644 --- a/python/libxml2class.txt +++ b/python/libxml2class.txt @@ -739,6 +739,7 @@ Class xmlTextReader(xmlTextReaderCore) Normalization() Prefix() Preserve() + PreservePattern() QuoteChar() Read() ReadAttributeValue() diff --git a/win32/libxml2.def.src b/win32/libxml2.def.src index a6cd721f..ab92f21c 100644 --- a/win32/libxml2.def.src +++ b/win32/libxml2.def.src @@ -778,6 +778,8 @@ xmlFreeNs xmlFreeNsList xmlFreeParserCtxt xmlFreeParserInputBuffer +xmlFreePattern +xmlFreePatternList xmlFreeProp xmlFreePropList xmlFreeRMutex @@ -1258,6 +1260,8 @@ xmlParserPrintFileInfo xmlParserValidityError xmlParserValidityWarning xmlParserWarning +xmlPatternMatch +xmlPatterncompile xmlPedanticParserDefault xmlPopInput xmlPrintURI @@ -1657,6 +1661,7 @@ xmlTextReaderNodeType xmlTextReaderNormalization xmlTextReaderPrefix xmlTextReaderPreserve +xmlTextReaderPreservePattern xmlTextReaderQuoteChar xmlTextReaderRead xmlTextReaderReadAttributeValue diff --git a/xmlreader.c b/xmlreader.c index efdba3d0..0295ddc3 100644 --- a/xmlreader.c +++ b/xmlreader.c @@ -41,6 +41,9 @@ #ifdef LIBXML_XINCLUDE_ENABLED #include #endif +#ifdef LIBXML_PATTERN_ENABLED +#include +#endif /* #define DEBUG_CALLBACKS */ /* #define DEBUG_READER */ @@ -147,10 +150,17 @@ struct _xmlTextReader { xmlXIncludeCtxtPtr xincctxt; /* the xinclude context */ int in_xinclude; /* counts for xinclude */ #endif +#ifdef LIBXML_PATTERN_ENABLED + int patternNr; /* number of preserve patterns */ + int patternMax; /* max preserve patterns */ + xmlPatternPtr *patternTab; /* array of preserve patterns */ +#endif + int preserves; /* level of preserves */ }; #define NODE_IS_EMPTY 0x1 #define NODE_IS_PRESERVED 0x2 +#define NODE_IS_SPRESERVED 0x4 /** * CONSTSTR: @@ -1255,13 +1265,19 @@ get_next_node: (reader->node->type == XML_ELEMENT_NODE)) xmlTextReaderValidatePop(reader); #endif /* LIBXML_REGEXP_ENABLED */ + if ((reader->preserves > 0) && + (reader->node->extra & NODE_IS_SPRESERVED)) + reader->preserves--; reader->node = reader->node->next; reader->state = XML_TEXTREADER_ELEMENT; /* * Cleanup of the old node */ - if ((reader->node->prev != NULL) && + if ((reader->preserves == 0) && + (reader->in_xinclude == 0) && + (reader->entNr == 0) && + (reader->node->prev != NULL) && (reader->node->prev->type != XML_DTD_NODE) && (reader->entNr == 0)) { xmlNodePtr tmp = reader->node->prev; @@ -1284,6 +1300,9 @@ get_next_node: if ((reader->validate) && (reader->node->type == XML_ELEMENT_NODE)) xmlTextReaderValidatePop(reader); #endif /* LIBXML_REGEXP_ENABLED */ + if ((reader->preserves > 0) && + (reader->node->extra & NODE_IS_SPRESERVED)) + reader->preserves--; reader->node = reader->node->parent; if ((reader->node == NULL) || (reader->node->type == XML_DOCUMENT_NODE) || @@ -1301,7 +1320,10 @@ get_next_node: /* * Cleanup of the old node */ - if ((oldnode->type != XML_DTD_NODE) && + if ((reader->preserves == 0) && + (reader->in_xinclude == 0) && + (reader->entNr == 0) && + (oldnode->type != XML_DTD_NODE) && ((oldnode->extra & NODE_IS_PRESERVED) == 0) && (reader->entNr == 0)) { xmlUnlinkNode(oldnode); @@ -1310,6 +1332,15 @@ get_next_node: goto node_end; } + if ((reader->preserves == 0) && + (reader->in_xinclude == 0) && + (reader->entNr == 0) && + (reader->node->last != NULL) && + ((reader->node->last->extra & NODE_IS_PRESERVED) == 0)) { + xmlNodePtr tmp = reader->node->last; + xmlUnlinkNode(tmp); + xmlTextReaderFreeNode(reader, tmp); + } reader->depth--; reader->state = XML_TEXTREADER_BACKTRACK; @@ -1403,6 +1434,18 @@ node_found: } } #endif /* LIBXML_REGEXP_ENABLED */ +#ifdef LIBXML_PATTERN_ENABLED + if ((reader->patternNr > 0) && (reader->state != XML_TEXTREADER_END) && + (reader->state != XML_TEXTREADER_BACKTRACK)) { + int i; + for (i = 0;i < reader->patternNr;i++) { + if (xmlPatternMatch(reader->patternTab[i], reader->node) == 1) { + xmlTextReaderPreserve(reader); + break; + } + } + } +#endif /* LIBXML_PATTERN_ENABLED */ return(1); node_end: reader->mode = XML_TEXTREADER_DONE; @@ -1858,6 +1901,10 @@ xmlNewTextReader(xmlParserInputBufferPtr input, const char *URI) { ret->dict = ret->ctxt->dict; #ifdef LIBXML_XINCLUDE_ENABLED ret->xinclude = 0; +#endif +#ifdef LIBXML_PATTERN_ENABLED + ret->patternMax = 0; + ret->patternTab = NULL; #endif return(ret); } @@ -1917,6 +1964,16 @@ xmlFreeTextReader(xmlTextReaderPtr reader) { #ifdef LIBXML_XINCLUDE_ENABLED if (reader->xincctxt != NULL) xmlXIncludeFreeContext(reader->xincctxt); +#endif +#ifdef LIBXML_PATTERN_ENABLED + if (reader->patternTab != NULL) { + int i; + for (i = 0;i < reader->patternNr;i++) { + if (reader->patternTab[i] != NULL) + xmlFreePattern(reader->patternTab[i]); + } + xmlFree(reader->patternTab); + } #endif if (reader->ctxt != NULL) { if (reader->dict == reader->ctxt->dict) @@ -3476,16 +3533,72 @@ xmlTextReaderPreserve(xmlTextReaderPtr reader) { cur = reader->node; if (cur == NULL) return(NULL); - cur->extra |= NODE_IS_PRESERVED; + + if (cur->type != XML_DOCUMENT_NODE) { + cur->extra |= NODE_IS_PRESERVED; + cur->extra |= NODE_IS_SPRESERVED; + } + reader->preserves++; parent = cur->parent;; while (parent != NULL) { - parent->extra |= NODE_IS_PRESERVED; + if (parent->type == XML_ELEMENT_NODE) + parent->extra |= NODE_IS_PRESERVED; parent = parent->parent; } return(cur); } +#ifdef LIBXML_PATTERN_ENABLED +/** + * xmlTextReaderPreservePattern: + * @reader: the xmlTextReaderPtr used + * @pattern: an XPath subset pattern + * + * This tells the XML Reader to preserve all nodes matched by the + * pattern. The caller must also use xmlTextReaderCurrentDoc() to + * keep an handle on the resulting document once parsing has finished + * + * Returns a positive number in case of success and -1 in case of error + */ +int +xmlTextReaderPreservePattern(xmlTextReaderPtr reader, const xmlChar *pattern) { + xmlPatternPtr comp; + + if ((reader == NULL) || (pattern == NULL)) + return(-1); + + comp = xmlPatterncompile(pattern, reader->dict, 0); + if (comp == NULL) + return(-1); + + if (reader->patternMax <= 0) { + reader->patternMax = 4; + reader->patternTab = (xmlPatternPtr *) xmlMalloc(reader->patternMax * + sizeof(reader->patternTab[0])); + if (reader->patternTab == NULL) { + xmlGenericError(xmlGenericErrorContext, "xmlMalloc failed !\n"); + return (-1); + } + } + if (reader->patternNr >= reader->patternMax) { + xmlPatternPtr *tmp; + reader->patternMax *= 2; + tmp = (xmlPatternPtr *) xmlRealloc(reader->patternTab, + reader->patternMax * + sizeof(reader->patternTab[0])); + if (tmp == NULL) { + xmlGenericError(xmlGenericErrorContext, "xmlRealloc failed !\n"); + reader->patternMax /= 2; + return (-1); + } + reader->patternTab = tmp; + } + reader->patternTab[reader->patternNr] = comp; + return(reader->patternNr++); +} +#endif + /** * xmlTextReaderCurrentDoc: * @reader: the xmlTextReaderPtr used @@ -4054,6 +4167,20 @@ xmlTextReaderSetup(xmlTextReaderPtr reader, reader->xinclude = 0; reader->in_xinclude = 0; #endif +#ifdef LIBXML_PATTERN_ENABLED + if (reader->patternTab == NULL) { + reader->patternNr = 0; + reader->patternMax = 0; + } + while (reader->patternNr > 0) { + reader->patternNr--; + if (reader->patternTab[reader->patternNr] != NULL) { + xmlFreePattern(reader->patternTab[reader->patternNr]); + reader->patternTab[reader->patternNr] = NULL; + } + } +#endif + if (options & XML_PARSE_DTDVALID) reader->validate = XML_TEXTREADER_VALIDATE_DTD; diff --git a/xmlwriter.c b/xmlwriter.c index f427200e..1585933c 100644 --- a/xmlwriter.c +++ b/xmlwriter.c @@ -984,7 +984,7 @@ xmlTextWriterWriteVFormatRaw(xmlTextWriterPtr writer, const char *format, } /** - * xmlTextWriterWriteStringLen: + * xmlTextWriterWriteRawLen: * @writer: the xmlTextWriterPtr * @content: text string * @len: length of the text string