1.5 ClassificationSet

ClassificationSet is a subpattern of the set pattern. ClassificationSet is used for dynamic classification of elements. ClassificationSet defines two additional attributes:

Let us illustrate by an abstract example, assuming that css1 contains the elements a, b and c, css2 contains the elements c, d and e, and finally cs contains the elements b and f:

Then after

cs will contain the original elements, and the css1 subset:

Note that the element b, originally located in both cs and css1, now is located exclusively in css1. In this situation, cs.scan(# ... #) will run through the elements a, b, c, d, e and f. and css1.scan(# ... #) will run through the elements b and f.

If we then execute

we will have the following situation:

Note again, that c is exclusively in css2. If we now execute

g[]->css1.insert; f[]->css2.insert; b[]->cs.delete
we will have the following situation:


css1.scanUnclassified(# ... #)
will only scan the elements a and b, whereas
css1.scan(# ... #)
will scan all elements (i.e. a, b, c, d, e, f and g).

Container Libraries - Reference Manual
© 1992-2002 Mjølner Informatics
[Modified: Thursday October 19th 2000 at 12:51]