[XML-SIG] Announcing PyXPath 1.2

Jeremy Kloth jeremy.kloth@fourthought.com
Thu, 18 Jan 2001 20:18:28 -0700

"Martin v. Loewis" wrote:
> The API is IDL based, which is meant in the same way as in the DOM:
> there is a (yet to be specified) mapping to Python, which roughly
> works that way:
> - global constants are defined in the module xml.xpath.
> - DOMString means Unicode objects, although normal strings should
>   be accepted were possible.
> - attributes are accessed as attributes; _get_ accessor functions
>   are optional.

Should the constants be defined where they are used?

The expression types in the Expr interface,
axis specifier types in the AxisSpecifier interface,
node test types in the NodeTest interface,

This would be similar to node types in Node, filter types in NodeFilter.

A benefit from this would be helping to avoiding circular imports.

xml.xpath -> (the parser) -> ExprFactory -> (constants from xml.xpath)
Sure imports could be done in the functions, but top level imports offer
some speed improvements.  Slight, but every little bit helps.

Jeremy Kloth                             Consultant
jeremy.kloth@fourthought.com             (303)583-9900 x 105
Fourthought, Inc.                        http://www.fourthought.com
Software-engineering, knowledge-management, XML, CORBA, Linux, Python