eXept Software AG Logo

Smalltalk/X Webserver

Documentation of class 'TreeSet':

Home

everywhere
www.exept.de
for:
[back]

Class: TreeSet


Inheritance:

   Object
   |
   +--Collection
      |
      +--TreeSet

Package:
stx:libbasic2
Category:
Collections-Ordered
Version:
rev: ? date: ? ?
user: ?
file: ? directory: libbasic2
module: stx stc-classLibrary: libbasic2
Author:
Avi Bryant

Description:


A bunch of collection classes that are useful for building large indices of things. 
It's especially geared towards people using OODBs like GOODS, but can be used it in the image too: 
the BTree class is great for when you need to select numeric keys by range, 
and TSTree makes a solid basis for full-text search. 
TreeSet has an interesting optimized #intersection: that lets you compare two collections without 
looking at every item of either. 
I'm also going to be rolling some code in here from Benjamin Pollack specifically aimed at indexing 
by date ranges, which lets you do quick queries of all the events that overlap with a specific week, 
for instance. 


[license:]
    Dual licensed under both SqueakL and MIT. 
    This enables both base Squeak inclusion and 100% reuse.


Class protocol:

as yet unclassified
o  keys: aBtreeKeys sortSelector: aSymbol

o  new

o  sortBy: aSymbol


Instance protocol:

initialize-release
o  initializeWithKeys: aBtreeKeys sortSelector: aSymbol

plugs
o  keyForValue: anObject

o  value: anObject matches: otherObject

private
o  bucket: anArray includes: anObject

o  tree

public
o  add: anObject

o  do: aBlock

o  includes: anObject

o  intersection: aCollection

o  remove: anObject

o  sortSelector



ST/X 6.1.1; WebServer 1.620 at exept:8081; Thu, 24 May 2012 04:38:51 GMT