summaryrefslogtreecommitdiffstats
path: root/Doc
diff options
context:
space:
mode:
authorMartin v. Löwis <martin@v.loewis.de>2001-02-22 14:05:50 (GMT)
committerMartin v. Löwis <martin@v.loewis.de>2001-02-22 14:05:50 (GMT)
commit7edbd4ffb4928d447c7d2a73e7cb7deddb30f0ac (patch)
treec9c08c012a49d432d97a5ac10753420a376e47a0 /Doc
parentf5d3ea00b97910bd14fa32fea46c29fae5775edd (diff)
downloadcpython-7edbd4ffb4928d447c7d2a73e7cb7deddb30f0ac.zip
cpython-7edbd4ffb4928d447c7d2a73e7cb7deddb30f0ac.tar.gz
cpython-7edbd4ffb4928d447c7d2a73e7cb7deddb30f0ac.tar.bz2
Patch #103885: Add dynamic registration and lookup of DOM implementations.
Diffstat (limited to 'Doc')
-rw-r--r--Doc/lib/xmldom.tex30
1 files changed, 30 insertions, 0 deletions
diff --git a/Doc/lib/xmldom.tex b/Doc/lib/xmldom.tex
index 5e752a0..87070b9 100644
--- a/Doc/lib/xmldom.tex
+++ b/Doc/lib/xmldom.tex
@@ -85,6 +85,36 @@ the strict mapping from IDL). See section \ref{dom-conformance},
{This specifies the mapping from OMG IDL to Python.}
\end{seealso}
+\subsection{Module Contents}
+
+The \module{xml.dom} contains the following functions:
+
+\begin{funcdesc}{registerDOMImplementation}{name, factory}
+Register the \var{factory} function with the \var{name}. The factory
+function should return an object which implements the
+\code{DOMImplementation| interface. The factory function can either return
+the same object, or a new one (e.g. if that implementation supports
+some customization).
+\end{funcdesc}
+
+\begin{funcdesc}{getDOMImplementation}{name = None, features = ()}
+Return a suitable DOM implementation. The \var{name} is either
+well-known, the module name of a DOM implementation, or
+\code{None}. If it is not \code{None}, imports the corresponding module and
+returns a \class{DOMImplementation} object if the import succeeds. If
+no name is given, and if the environment variable \code{PYTHON_DOM} is
+set, this variable is used to find the implementation.
+
+If name is not given, consider the available implementations to find
+one with the required feature set. If no implementation can be found,
+raise an \exception{ImportError}. The features list must be a sequence of
+(feature, version) pairs which are passed to hasFeature.
+\end{funcdesc}
+
+% Should the Node documentation go here?
+
+In addition, \module{xml.dom} contains the \class{Node}, and the DOM
+exceptions.
\subsection{Objects in the DOM \label{dom-objects}}