tzh
2024-08-22 c7d0944258c7d0943aa7b2211498fd612971ce27
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
\\¬Qc@sXdZddlTidd6dd6ZiZd„Zd„Zd d d    „Zd
„Zd S( s´Registration facilities for DOM. This module should not be used
directly. Instead, the functions getDOMImplementation and
registerDOMImplementation should be imported from xml.dom.iÿÿÿÿ(t*sxml.dom.minidomtminidomsxml.dom.DOMImplementationt4DOMcCs|t|<dS(sIregisterDOMImplementation(name, factory)
 
    Register the factory function with the name. The factory function
    should return an object which implements the DOMImplementation
    interface. The factory function can either return the same object,
    or a new one (e.g. if that implementation supports some
    customization).N(t
registered(tnametfactory((sV/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/xml/dom/domreg.pytregisterDOMImplementations    cCs1x*|D]"\}}|j||ƒsdSqWdS(sF_good_enough(dom, features) -> Return 1 if the dom offers the featuresii(t
hasFeature(tdomtfeaturestftv((sV/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/xml/dom/domreg.pyt _good_enough scCs/ddl}d}tj|ƒ}|rIt|iidgƒ}|jƒS|rZt|ƒSd|jkr}td|jdƒSt|t    ƒr›t
|ƒ}nx0tj ƒD]"}|ƒ}t ||ƒr¨|Sq¨WxQtj ƒD]C}ytd|ƒ}Wntk
r
qÛnXt ||ƒrÛ|SqÛWtd‚dS(sSgetDOMImplementation(name = None, features = ()) -> DOM implementation.
 
    Return a suitable DOM implementation. The name is either
    well-known, the module name of a DOM implementation, or None. If
    it is not None, imports the corresponding module and returns
    DOMImplementation object if the import succeeds.
 
    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 ImportError. The features list must be a sequence
    of (feature, version) pairs which are passed to hasFeature.iÿÿÿÿNtgetDOMImplementationt
PYTHON_DOMRs$no suitable DOM implementation found(tostNonetwell_known_implementationstgett
__import__R Rtenviront
isinstancet StringTypest_parse_feature_stringtvaluesR tkeyst StandardErrort ImportError(RR    RtcreatortmodR((sV/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/xml/dom/domreg.pyR 's0 
      cCsÍg}|jƒ}d}t|ƒ}xœ||krÂ||}|ddkr`td|f‚n|d}d}||kr¬||}|ddkr¬|d}|}q¬n|j||fƒq'Wt|ƒS(Nit
0123456789sbad feature name: %ri(tsplittlent
ValueErrorRtappendttuple(tsR    tpartstitlengthtfeaturetversionR ((sV/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/xml/dom/domreg.pyRRs"  
 
 
 
 N((    t__doc__txml.dom.minicompatRRRR RR R(((sV/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/xml/dom/domreg.pyt<module>s
 
        +