Difference between revisions of "ObjectType:set"

From Lavish Software Wiki
Jump to navigation Jump to search
Line 5: Line 5:
  
 
== Members ==
 
== Members ==
* [[ObjectType:bool|bool]] '''Contains['''key''']''':
+
* [[ObjectType:bool|bool]] '''Contains['''key''']''': TRUE if the given key exists in the set
* [[ObjectType:string|string]] '''FirstKey''':
 
* [[ObjectType:string|string]] '''NextKey''':
 
* [[ObjectType:string|string]] '''CurrentKey''':
 
  
 
== Methods ==
 
== Methods ==
*'''Add['''key''']''':
+
*'''Add['''key''']''': Adds a given key to the set
*'''Remove['''key''']''':
+
*'''Remove['''key''']''': Removes a given key from the set
*'''Intersect''':
+
*'''Intersect['''set A''','''set B''']''': Adds "sets A and intersect B" to this set
*'''Union''':
+
*'''Union['''set A''','''set B''']''': Adds "set A union B" to this set
*'''Not''':
+
*'''Not['''set A''','''set B''']''': Adds "set A not B" to this set
*'''Minus''':
+
*'''Minus['''set A''','''set B''']''': Adds "set A minus B" to this set
*'''NotIntersect''':
+
*'''NotIntersect['''set A''','''set B''']''': Adds "set A not intersect B" to this set
  
 
== See Also ==
 
== See Also ==

Revision as of 04:56, 8 May 2006

Overview

Object Type Vitals
set
Defined By LavishScript
Inherits objectcontainer
Reduces To NULL
Variable Object Type set
Uses Sub-Types no
C/C++ Type LSSet *

A set is a sorted list of keys. It can be thought of as a collection where the key is the object -- the key is either present, or it is absent. Keys are text, and not case sensitive.

Members

  • bool Contains[key]: TRUE if the given key exists in the set

Methods

  • Add[key]: Adds a given key to the set
  • Remove[key]: Removes a given key from the set
  • Intersect[set A,set B]: Adds "sets A and intersect B" to this set
  • Union[set A,set B]: Adds "set A union B" to this set
  • Not[set A,set B]: Adds "set A not B" to this set
  • Minus[set A,set B]: Adds "set A minus B" to this set
  • NotIntersect[set A,set B]: Adds "set A not intersect B" to this set

See Also