diff options
author | Al <albarrentine@gmail.com> | 2017-04-12 23:08:30 -0400 |
---|---|---|
committer | Al <albarrentine@gmail.com> | 2017-04-14 04:23:42 -0400 |
commit | e55b098fa2f8bca2dc21705d518936151cbda412 (patch) | |
tree | b138e0f3748ce7d811a3ceff36c770ac69751f08 /src/lxml/public-api.pxi | |
parent | 41ebfd3332410711e64bff24b460f1ac82a4c7f0 (diff) | |
download | python-lxml-e55b098fa2f8bca2dc21705d518936151cbda412.tar.gz |
add documentFactory to public header
Diffstat (limited to 'src/lxml/public-api.pxi')
-rw-r--r-- | src/lxml/public-api.pxi | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/lxml/public-api.pxi b/src/lxml/public-api.pxi index 128e25d3..f56c162a 100644 --- a/src/lxml/public-api.pxi +++ b/src/lxml/public-api.pxi @@ -17,6 +17,11 @@ cdef public api _ElementTree newElementTree(_Element context_node, _assertValidNode(context_node) return _newElementTree(context_node._doc, context_node, subclass) +cdef public api _Document documentFactory(xmlDoc* c_doc, parser): + if c_doc is NULL: + raise TypeError + return _documentFactory(c_doc, parser) + cdef public api _Element elementFactory(_Document doc, xmlNode* c_node): if c_node is NULL or doc is None: raise TypeError |