Class: Sketchup::Set Deprecated
- Inherits:
-
Object
- Object
- Sketchup::Set
Overview
In SketchUp 2014 this class was changed from Set
to Sketchup::Set
in order to avoid conflict with the Ruby Standard Library. The Sketchup::Set
class is deprecated and new extensions should make use of Ruby's Set
class unless they need backward compatibility.
The set class represents a collection of unique objects. This class is useful for keeping track of a group of related entities, kind of like a selection set that stays around for as long as you need it to.
To make a set of your own, create an empty one using Sketchup::Set.new, and then add items to it.
Instance Method Summary # collapse
-
#clear ⇒ Object
The clear method is used to clear all objects out of the set.
-
#contains?(entity) ⇒ Boolean
The #contains? method is an alias for #include?.
-
#delete(object) ⇒ Object
The delete object is used to delete or remove an object from the set.
-
#each {|item| ... } ⇒ Object
The each method is used to iterate through all of the objects in the set.
-
#empty? ⇒ Boolean
The empty? method is used to determine whether the set is empty.
-
#include?(entity) ⇒ Boolean
The #include? method is used to determine if the set includes a particular object.
-
#insert(object) ⇒ Object
The insert method is used to insert an object into the set.
- #length ⇒ Integer
-
#size ⇒ Integer
The #size method is used to determine the number of objects in the set.
-
#to_a ⇒ Object
The to_a method is used to get an Array of the entities in your Set.
Instance Method Details
↑ #clear ⇒ Object
The clear method is used to clear all objects out of the set.
↑ #contains?(entity) ⇒ Boolean
The #contains? method is an alias for #include?.
↑ #delete(object) ⇒ Object
The delete object is used to delete or remove an object from the set.
↑ #each {|item| ... } ⇒ Object
The each method is used to iterate through all of the objects in the set.
↑ #empty? ⇒ Boolean
The empty? method is used to determine whether the set is empty.
↑ #include?(entity) ⇒ Boolean
The #include? method is used to determine if the set includes a particular object.
↑ #insert(object) ⇒ Object
The insert method is used to insert an object into the set.
↑ #to_a ⇒ Object
The to_a method is used to get an Array of the entities in your Set.