Commit 1f579316 authored by Andreas Jung's avatar Andreas Jung

adjusted references to changes in STXNG

parent 5c3ff518
...@@ -103,8 +103,8 @@ ...@@ -103,8 +103,8 @@
over acquisition. This is done by:</p> over acquisition. This is done by:</p>
<ul> <ul>
<li><p>subclassing from <code>Acquisition.Explicit</code>, and</p></li> <li>subclassing from <code>Acquisition.Explicit</code>, and</li>
<li><p>setting all attributes that should be acquired to the special <li>setting all attributes that should be acquired to the special
value: <code>Acquisition.Acquired</code>. Setting an attribute to this value: <code>Acquisition.Acquired</code>. Setting an attribute to this
value also allows inherited attributes to be overridden with value also allows inherited attributes to be overridden with
acquired ones.<p> For example, in: acquired ones.<p> For example, in:
...@@ -123,7 +123,7 @@ ...@@ -123,7 +123,7 @@
<code>Acquisition.Acquired</code> value can be used in <code>Acquisition.Acquired</code> value can be used in
<code>Acquisition.Implicit</code> objects to implicitly acquire selected <code>Acquisition.Implicit</code> objects to implicitly acquire selected
objects that smell like private objects.</p> objects that smell like private objects.</p>
</p></li> </li>
</ul> </ul>
<h3> Filtered Acquisition</h3> <h3> Filtered Acquisition</h3>
...@@ -136,11 +136,11 @@ ...@@ -136,11 +136,11 @@
<p> The filter function is called with five arguments:</p> <p> The filter function is called with five arguments:</p>
<ul> <ul>
<li><p>The object that the <code>aq_acquire</code> method was called on,</p></li> <li>The object that the <code>aq_acquire</code> method was called on,</li>
<li><p>The object where an object was found,</p></li> <li>The object where an object was found,</li>
<li><p>The name of the object, as passed to <code>aq_acquire</code>,</p></li> <li>The name of the object, as passed to <code>aq_acquire</code>,</li>
<li><p>The object found, and</p></li> <li>The object found, and</li>
<li><p>The extra data passed to <code>aq_acquire</code>.</p></li> <li>The extra data passed to <code>aq_acquire</code>.</li>
</ul> </ul>
<p> If the filter returns a true object that the object found is <p> If the filter returns a true object that the object found is
......
...@@ -14,9 +14,9 @@ ...@@ -14,9 +14,9 @@
treated like other python classes:</p> treated like other python classes:</p>
<ul> <ul>
<li><p>They can be sub-classed in python,</p></li> <li>They can be sub-classed in python,</li>
<li><p>They provide access to method documentation strings, and</p></li> <li>They provide access to method documentation strings, and</li>
<li><p>They can be used to directly create new instances.</p></li> <li>They can be used to directly create new instances.</li>
</ul> </ul>
<p> An example class shows how extension classes are implemented and how <p> An example class shows how extension classes are implemented and how
...@@ -25,15 +25,15 @@ ...@@ -25,15 +25,15 @@
instance semantics, including:</p> instance semantics, including:</p>
<ul> <ul>
<li><p>A protocol for accessing subobjects "in the context of" their <li>A protocol for accessing subobjects "in the context of" their
containers. This is used to implement custom method types containers. This is used to implement custom method types
and <a href="Acquisition.html">environmental acquisition</a>.</p></li> and <a href="Acquisition.html">environmental acquisition</a>.</li>
<li><p>A protocol for overriding method call semantics. This is used <li>A protocol for overriding method call semantics. This is used
to implement "synchonized" classes and could be used to to implement "synchonized" classes and could be used to
implement argument type checking.</p></li> implement argument type checking.</li>
<li><p>A protocol for class initialization that supports execution of a <li>A protocol for class initialization that supports execution of a
special <code>__class_init__</code> method after a class has been special <code>__class_init__</code> method after a class has been
initialized. </p></li> initialized. </li>
</ul> </ul>
<p> Extension classes illustrate how the Python class mechanism can be <p> Extension classes illustrate how the Python class mechanism can be
...@@ -46,8 +46,8 @@ ...@@ -46,8 +46,8 @@
<p> Currently, Python provides two ways of defining new kinds of objects:</p> <p> Currently, Python provides two ways of defining new kinds of objects:</p>
<ul> <ul>
<li><p>Python classes</p></li> <li>Python classes</li>
<li><p>Extension types</p></li> <li>Extension types</li>
</ul> </ul>
<p> Each approach has it's strengths. Extension types provide much greater <p> Each approach has it's strengths. Extension types provide much greater
...@@ -104,15 +104,15 @@ ...@@ -104,15 +104,15 @@
provided a number of important features, including:</p> provided a number of important features, including:</p>
<ul> <ul>
<li><p>Definition of extension types that provide class-like meta-data <li>Definition of extension types that provide class-like meta-data
and that can be called to create instances.</p></li> and that can be called to create instances.</li>
<li><p>Ability to subclass in python from C types.</p></li> <li>Ability to subclass in python from C types.</li>
<li><p>Ability to define classes in python who's data are stored as <li>Ability to define classes in python who's data are stored as
C structures rather than in dictionaries to better interface to C structures rather than in dictionaries to better interface to
C and C++ libraries, and for better performance.</p></li> C and C++ libraries, and for better performance.</li>
<li><p>Less dynamic data structures. In particular, the data structure <li>Less dynamic data structures. In particular, the data structure
for a class is declared during class definition.</p></li> for a class is declared during class definition.</li>
<li><p>Support for enumeration types.</p></li> <li>Support for enumeration types.</li>
</ul> </ul>
<p> This work was not released, initially.</p> <p> This work was not released, initially.</p>
...@@ -130,20 +130,20 @@ ...@@ -130,20 +130,20 @@
has a few drawbacks:</p> has a few drawbacks:</p>
<ul> <ul>
<li><p>Only single inheritance is supported.</p></li> <li>Only single inheritance is supported.</li>
<li><p>The mechanisms for defining MESS extension types is very different <li>The mechanisms for defining MESS extension types is very different
from and more complicated than the standard Python type creation from and more complicated than the standard Python type creation
mechanism.</p></li> mechanism.</li>
<li><p>Defining MESS types requires the use of an extensive C <li>Defining MESS types requires the use of an extensive C
applications programming interface. This presents problems for applications programming interface. This presents problems for
configuring dynamically-loaded extension modules unless the MESS configuring dynamically-loaded extension modules unless the MESS
library is linked into the Python interpreter.</p></li> library is linked into the Python interpreter.</li>
<li><p>Because the system tries to do a number of different things, it is <li>Because the system tries to do a number of different things, it is
fairly large, about 15,000 lines.</p></li> fairly large, about 15,000 lines.</li>
<li><p>There is very little documentation, especially for the C <li>There is very little documentation, especially for the C
programming interface.</p></li> programming interface.</li>
<li><p>The system is a work in progress, with a number of outstanding <li>The system is a work in progress, with a number of outstanding
bugs.</p></li> bugs.</li>
</ul> </ul>
<p> As MESS matures, we expect most of these problems to be addressed.</p> <p> As MESS matures, we expect most of these problems to be addressed.</p>
...@@ -156,16 +156,16 @@ ...@@ -156,16 +156,16 @@
classes. The module was designed to meet the following goal:</p> classes. The module was designed to meet the following goal:</p>
<ul> <ul>
<li><p>Provide class-like behavior for extension types, including <li>Provide class-like behavior for extension types, including
interfaces for meta information and for constructing instances.</p></li> interfaces for meta information and for constructing instances.</li>
<li><p>Support sub-classing in Python from extension classes, with support <li>Support sub-classing in Python from extension classes, with support
for multiple inheritance.</p></li> for multiple inheritance.</li>
<li><p>Provide a small hardened implementation that can be used for <li>Provide a small hardened implementation that can be used for
current products.</p></li> current products.</li>
<li><p>Provide a mechanism that requires minimal modification to existing <li>Provide a mechanism that requires minimal modification to existing
extension types.</p></li> extension types.</li>
<li><p>Provide a basis for research on alternative semantics for classes <li>Provide a basis for research on alternative semantics for classes
and inheritance.</p></li> and inheritance.</li>
</ul> </ul>
<p> <strong>Note:</strong> I use <em>non-standard</em> terminology here. By standard <p> <strong>Note:</strong> I use <em>non-standard</em> terminology here. By standard
...@@ -182,14 +182,14 @@ ...@@ -182,14 +182,14 @@
following two rules:</p> following two rules:</p>
<ul> <ul>
<li><p>The first super class listed in the class statement defining an <li>The first super class listed in the class statement defining an
extension subclass must be either a base extension class or an extension subclass must be either a base extension class or an
extension subclass. This restriction will be removed in extension subclass. This restriction will be removed in
Python-1.5.</p></li> Python-1.5.</li>
<li><p>At most one base extension direct or indirect super class may <li>At most one base extension direct or indirect super class may
define C data members. If an extension subclass inherits from define C data members. If an extension subclass inherits from
multiple base extension classes, then all but one must be mix-in multiple base extension classes, then all but one must be mix-in
classes that provide extension methods but no data.</p></li> classes that provide extension methods but no data.</li>
</ul> </ul>
<h3> Meta Information</h3> <h3> Meta Information</h3>
...@@ -227,10 +227,10 @@ ...@@ -227,10 +227,10 @@
extension type is implemented, except:</p> extension type is implemented, except:</p>
<ul> <ul>
<li><p>The include file, <code>ExtensionClass.h</code>, must be included.</p></li> <li>The include file, <code>ExtensionClass.h</code>, must be included.</li>
<li><p>The type structure is declared to be of type <code>PyExtensionClass</code>, rather <li>The type structure is declared to be of type <code>PyExtensionClass</code>, rather
than of type <code>PyTypeObject</code>.</p></li> than of type <code>PyTypeObject</code>.</li>
<li><p>The type structure has an additional member that must be defined <li>The type structure has an additional member that must be defined
after the documentation string. This extra member is a method chain after the documentation string. This extra member is a method chain
(<code>PyMethodChain</code>) containing a linked list of method definition (<code>PyMethodChain</code>) containing a linked list of method definition
(<code>PyMethodDef</code>) lists. Method chains can be used to implement (<code>PyMethodDef</code>) lists. Method chains can be used to implement
...@@ -238,16 +238,16 @@ ...@@ -238,16 +238,16 @@
but simply define method lists, which are null-terminated arrays but simply define method lists, which are null-terminated arrays
of method definitions. A macro, <code>METHOD_CHAIN</code> is defined in of method definitions. A macro, <code>METHOD_CHAIN</code> is defined in
<code>ExtensionClass.h</code> that converts a method list to a method chain. <code>ExtensionClass.h</code> that converts a method list to a method chain.
(See the example below.)</p></li> (See the example below.)</li>
<li><p>Module functions that create new instances must be replaced by <li>Module functions that create new instances must be replaced by
<code>__init__</code> methods that initialize, but does not create storage for <code>__init__</code> methods that initialize, but does not create storage for
instances.</p></li> instances.</li>
<li><p>The extension class must be initialized and exported to the module <li>The extension class must be initialized and exported to the module
with: with:
<pre> <pre>
PyExtensionClass_Export(d,"name",type); PyExtensionClass_Export(d,"name",type);
</pre> </pre>
</p></li> </li>
</ul> </ul>
<p> where <code>name</code> is the module name and <code>type</code> is the extension class <p> where <code>name</code> is the module name and <code>type</code> is the extension class
...@@ -352,9 +352,9 @@ ...@@ -352,9 +352,9 @@
<h4> We have found many applications for this, including:</h4> <h4> We have found many applications for this, including:</h4>
<ul> <ul>
<li><p>User-defined method objects, </p></li> <li>User-defined method objects, </li>
<li><p><a href="Acquisition.html">Acquisition</a>, and</p></li> <li><a href="Acquisition.html">Acquisition</a>, and</li>
<li><p>Computed attributes</p></li> <li>Computed attributes</li>
</ul> </ul>
<h4> User-defined method objects</h4> <h4> User-defined method objects</h4>
...@@ -508,7 +508,7 @@ ...@@ -508,7 +508,7 @@
and that deserve mention.</p> and that deserve mention.</p>
<ul> <ul>
<li><p>In Python 1.4, the class extension mechanism described in <a href="#ref4">[4]</a> required <li>In Python 1.4, the class extension mechanism described in <a href="#ref4">[4]</a> required
that the first superclass in a list of super-classes must be of the that the first superclass in a list of super-classes must be of the
extended class type. This may not be convenient if mix-in extended class type. This may not be convenient if mix-in
behavior is desired. If a list of base classes starts with a behavior is desired. If a list of base classes starts with a
...@@ -525,8 +525,8 @@ ...@@ -525,8 +525,8 @@
the restriction that the first non-class object in a list of the restriction that the first non-class object in a list of
base classes must be the first in the list may reappear in later base classes must be the first in the list may reappear in later
versions of Python.</p> versions of Python.</p>
</p></li> </li>
<li><p>Currently, only one base extension class can define any data in <li>Currently, only one base extension class can define any data in
C. The data layout of subclasses-instances is the same as for the C. The data layout of subclasses-instances is the same as for the
base class that defines data in C, except that the data structure base class that defines data in C, except that the data structure
is extended to hold an instance dictionary. The data structure is extended to hold an instance dictionary. The data structure
...@@ -540,10 +540,10 @@ ...@@ -540,10 +540,10 @@
to make sure that methods were bound to the correct base data to make sure that methods were bound to the correct base data
structure. Alternatively, the signature of C methods could be structure. Alternatively, the signature of C methods could be
expanded to allow pointers to expected class data to be passed expanded to allow pointers to expected class data to be passed
in addition to object pointers.</p></li> in addition to object pointers.</li>
<li><p>There is currently no support for sub-classing in C, beyond that <li>There is currently no support for sub-classing in C, beyond that
provided by method chains.</p></li> provided by method chains.</li>
<li><p>Rules for mixed-type arithmetic are different for python class <li>Rules for mixed-type arithmetic are different for python class
instances than they are for extension type instances. Python instances than they are for extension type instances. Python
classes can define right and left versions of numeric binary classes can define right and left versions of numeric binary
operators, or they can define a coercion operator for converting operators, or they can define a coercion operator for converting
...@@ -554,20 +554,20 @@ ...@@ -554,20 +554,20 @@
classes are based on extension types, they are currently limited classes are based on extension types, they are currently limited
to the coercion-based approach. It should be possible to to the coercion-based approach. It should be possible to
extend the extension class implementation to allow both types of extend the extension class implementation to allow both types of
mixed-type arithmetic control.</p></li> mixed-type arithmetic control.</li>
<li><p>I considered making extension classes immutable, meaning that <li>I considered making extension classes immutable, meaning that
class attributes could not be set after class creation. I also class attributes could not be set after class creation. I also
considered making extension subclasses cache inherited considered making extension subclasses cache inherited
attributes. Both of these are related and attractive for some attributes. Both of these are related and attractive for some
applications, however, I decided that it would be better to retain applications, however, I decided that it would be better to retain
standard class instance semantics and provide these features as standard class instance semantics and provide these features as
options at a later time.</p></li> options at a later time.</li>
<li><p>The extension class module defines new method types to bind C and <li>The extension class module defines new method types to bind C and
python methods to extension class instances. It would be useful python methods to extension class instances. It would be useful
for these method objects to provide access to function call for these method objects to provide access to function call
information, such as the number and names of arguments and the information, such as the number and names of arguments and the
number of defaults, by parsing extension function documentation number of defaults, by parsing extension function documentation
strings.</p></li> strings.</li>
</ul> </ul>
<h2> Applications</h2> <h2> Applications</h2>
...@@ -583,11 +583,11 @@ ...@@ -583,11 +583,11 @@
<p> The extension-class mechanism described here provides a way to add <p> The extension-class mechanism described here provides a way to add
class services to extension types. It allows: class services to extension types. It allows:
<ul> <ul>
<li><p>Sub-classing extension classes in Python,</p></li> <li>Sub-classing extension classes in Python,</li>
<li><p>Construction of extension class instances by calling extension <li>Construction of extension class instances by calling extension
classes,</p></li> classes,</li>
<li><p>Extension classes to provide meta-data, such as unbound methods <li>Extension classes to provide meta-data, such as unbound methods
and their documentation string.</p></li> and their documentation string.</li>
</ul> </ul>
</p> </p>
......
...@@ -6,15 +6,15 @@ ...@@ -6,15 +6,15 @@
<h1>This is LinkTest</h1> <h1>This is LinkTest</h1>
<ul> <ul>
<li><p>please click <a href="/Members/Zope">here</a></p></li> <li>please click <a href="/Members/Zope">here</a></li>
<li><p>please click <a href="/Members/Zope?a=b&c=d%20blabla">here</a></p></li> <li>please click <a href="/Members/Zope?a=b&c=d%20blabla">here</a></li>
<li><p>please click <a href="http://www.zope.org">here</a></p></li> <li>please click <a href="http://www.zope.org">here</a></li>
<li><p>please click <a href="http://www.zope.org/members/">here</a></p></li> <li>please click <a href="http://www.zope.org/members/">here</a></li>
<li><p>please click <a href="http://www.zope.org:2001">here</a> </p></li> <li>please click <a href="http://www.zope.org:2001">here</a> </li>
<li><p>please click <a href="http://www.zope.org:2001/members/">here</a></p></li> <li>please click <a href="http://www.zope.org:2001/members/">here</a></li>
<li><p>please click <a href="http://www.zope.org:2001/%20/Members/zope?a=222&b=213&_xc=just%20a%20test">here</a> </p></li> <li>please click <a href="http://www.zope.org:2001/%20/Members/zope?a=222&b=213&_xc=just%20a%20test">here</a> </li>
<li><p>please click <a href="http://www.zope.org:2001/%20/Members/zope?a=222&b=213&_xc=just%20a%20test">here</a> </p></li> <li>please click <a href="http://www.zope.org:2001/%20/Members/zope?a=222&b=213&_xc=just%20a%20test">here</a> </li>
<li><p>please click <a href="http://www.zope.org:2001/%20/Members/zope?a=222&b=213&_xc=just%20a%20test">here</a> </p></li> <li>please click <a href="http://www.zope.org:2001/%20/Members/zope?a=222&b=213&_xc=just%20a%20test">here</a> </li>
</ul> </ul>
<p> And now a paragraph with <a href="http://www.zope-rocks.org">Link 1</a> and <p> And now a paragraph with <a href="http://www.zope-rocks.org">Link 1</a> and
......
...@@ -9,15 +9,15 @@ ...@@ -9,15 +9,15 @@
<p> Here are a few presentation styles, in a list <a href="#ref1">[1]</a>:</p> <p> Here are a few presentation styles, in a list <a href="#ref1">[1]</a>:</p>
<ul> <ul>
<li><p>A word: <em>emphasized</em>.</p></li> <li>A word: <em>emphasized</em>.</li>
<li><p>A word: <u>underlined</u>.</p></li> <li>A word: <u>underlined</u>.</li>
<li><p>A word <strong>strong</strong>.</p></li> <li>A word <strong>strong</strong>.</li>
<li><p>An inline example: <code>1+2</code>.</p></li> <li>An inline example: <code>1+2</code>.</li>
<li><p>Another example with a different format: <li>Another example with a different format:
``x='spam''' or ``y='spam''' or ``<dtml-var spam>'<code>.</code><p> We can use expressions in the DTML var tag as ``x='spam''' or ``y='spam''' or ``<dtml-var spam>'<code>.</code><p> We can use expressions in the DTML var tag as
in ``<dtml-var "x+'.txt'">''</p> in ``<dtml-var "x+'.txt'">''</p>
</p></li> </li>
<li><p>A mult-line example: <li>A mult-line example:
<pre> <pre>
blah blah
...@@ -25,7 +25,7 @@ ...@@ -25,7 +25,7 @@
&lt;dtml-var yeha&gt; &lt;dtml-var yeha&gt;
</pre> </pre>
</p></li> </li>
</ul> </ul>
<p><a name="ref1">[1]</a> (The referring text should be a paragraph, not a header, and <p><a name="ref1">[1]</a> (The referring text should be a paragraph, not a header, and
...@@ -46,4 +46,3 @@ should contain a reference to this footnote, footnote "<a href="#ref1">[1]</a>". ...@@ -46,4 +46,3 @@ should contain a reference to this footnote, footnote "<a href="#ref1">[1]</a>".
</p> </p>
</body> </body>
</html> </html>
...@@ -11,24 +11,24 @@ ...@@ -11,24 +11,24 @@
treated like other python classes:</p> treated like other python classes:</p>
<ul> <ul>
<li><p>They can be sub-classed in python,</p></li> <li>They can be sub-classed in python,</li>
<li><p>They provide access to method documentation strings, and</p></li> <li>They provide access to method documentation strings, and</li>
<li><p>They can be used to directly create new instances.</p></li> <li>They can be used to directly create new instances.</li>
</ul> </ul>
<p> Extension classes provide additional extensions to class and <p> Extension classes provide additional extensions to class and
instance semantics, including:</p> instance semantics, including:</p>
<ul> <ul>
<li><p>A protocol for accessing subobjects "in the context of" their <li>A protocol for accessing subobjects "in the context of" their
containers. This is used to implement custom method types containers. This is used to implement custom method types
and <a href="Acquisition.html">environmental acquisition</a>.</p></li> and <a href="Acquisition.html">environmental acquisition</a>.</li>
<li><p>A protocol for overriding method call semantics. This is used <li>A protocol for overriding method call semantics. This is used
to implement "synchonized" classes and could be used to to implement "synchonized" classes and could be used to
implement argument type checking.</p></li> implement argument type checking.</li>
<li><p>A protocol for class initialization that supports execution of a <li>A protocol for class initialization that supports execution of a
special <code>__class_init__</code> method after a class has been special <code>__class_init__</code> method after a class has been
initialized. </p></li> initialized. </li>
</ul> </ul>
<p> Extension classes illustrate how the Python class mechanism can be <p> Extension classes illustrate how the Python class mechanism can be
......
...@@ -14,8 +14,8 @@ ...@@ -14,8 +14,8 @@
the object to a string. </p> the object to a string. </p>
<ul> <ul>
<li><p>Blah </p></li> <li>Blah </li>
<li><p>Blaf <table border="1" cellpadding="2"> <li>Blaf <table border="1" cellpadding="2">
<tr> <tr>
<th colspan="1" align="center" valign="top"><p> Name </p> <th colspan="1" align="center" valign="top"><p> Name </p>
</th> </th>
...@@ -36,7 +36,7 @@ ...@@ -36,7 +36,7 @@
</td> </td>
</tr> </tr>
</table> </table>
</p></li> </li>
</ul> </ul>
</td> </td>
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment