Class: Sketchup::Set Deprecated
- Inherits:
-
Object
- Object
- Sketchup::Set
- Defined in:
- lib/sketchup-api-stubs/stubs/Sketchup/Set.rb
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.
56 57 |
# File 'lib/sketchup-api-stubs/stubs/Sketchup/Set.rb', line 56 def clear end |
#contains?(entity) ⇒ Boolean
The #contains? method is an alias for #include?.
75 76 |
# File 'lib/sketchup-api-stubs/stubs/Sketchup/Set.rb', line 75 def contains?(entity) end |
#delete(object) ⇒ Object
The delete object is used to delete or remove an object from the set.
92 93 |
# File 'lib/sketchup-api-stubs/stubs/Sketchup/Set.rb', line 92 def delete(object) end |
#each {|item| ... } ⇒ Object
The each method is used to iterate through all of the objects in the set.
107 108 |
# File 'lib/sketchup-api-stubs/stubs/Sketchup/Set.rb', line 107 def each end |
#empty? ⇒ Boolean
The empty? method is used to determine whether the set is empty.
123 124 |
# File 'lib/sketchup-api-stubs/stubs/Sketchup/Set.rb', line 123 def empty? end |
#include?(entity) ⇒ Boolean
The #include? method is used to determine if the set includes a particular object.
143 144 |
# File 'lib/sketchup-api-stubs/stubs/Sketchup/Set.rb', line 143 def include?(entity) end |
#insert(object) ⇒ Object
The insert method is used to insert an object into the set.
160 161 |
# File 'lib/sketchup-api-stubs/stubs/Sketchup/Set.rb', line 160 def insert(object) end |
#length ⇒ Integer
177 178 |
# File 'lib/sketchup-api-stubs/stubs/Sketchup/Set.rb', line 177 def length end |
#size ⇒ Integer
The #size method is used to determine the number of objects in the set.
194 195 |
# File 'lib/sketchup-api-stubs/stubs/Sketchup/Set.rb', line 194 def size end |
#to_a ⇒ Object
The to_a method is used to get an Array of the entities in your Set.
209 210 |
# File 'lib/sketchup-api-stubs/stubs/Sketchup/Set.rb', line 209 def to_a end |