class Microstation::TagSet

Attributes

drawing[R]
instances[R]
ole_obj[R]

Public Class Methods

new(drawing,ole) click to toggle source
# File lib/microstation/tag_set.rb, line 247
def initialize(drawing,ole)
  @drawing = drawing
  @ole_obj = ole
  @instances = nil
end

Public Instance Methods

==(other) click to toggle source
# File lib/microstation/tag_set.rb, line 329
def ==(other)
  @ole_obj == other.ole_obj
end
[](name) click to toggle source
# File lib/microstation/tag_set.rb, line 341
def [](name)
  definition[name]
end
add_attribute(name,type,**options, &block) click to toggle source
# File lib/microstation/tag_set.rb, line 253
def add_attribute(name,type,**options, &block)
  ts = definition.add_attribute(name,type,**options, &block)
end
add_instance(array) click to toggle source

def definer

@definer ||= Definer.new(self)

end

# File lib/microstation/tag_set.rb, line 263
def add_instance(array)
  @instances << TS::Instance.new(self,array)
end
attribute_names() click to toggle source
# File lib/microstation/tag_set.rb, line 333
def attribute_names
  definition.attribute_names
end
attributes() click to toggle source
# File lib/microstation/tag_set.rb, line 337
def attributes
  definition.attributes
end
close() click to toggle source

def all_tags_in_drawing

Microstation.app.current_drawing.scan_tags

end

# File lib/microstation/tag_set.rb, line 317
def close
  @ole_obj = nil
end
create_instance(base_element_id , tags , model ) click to toggle source
# File lib/microstation/tag_set.rb, line 267
def create_instance(base_element_id , tags , model )
  if @instaces.nil?
    @instance = []
    ti = TS::Instances.new(self, base_element_id, tags, model)
    @instances << ti
    ti
 end 
end
name() click to toggle source
# File lib/microstation/tag_set.rb, line 321
def name
  @ole_obj.name
end
to_s() click to toggle source
# File lib/microstation/tag_set.rb, line 325
def to_s
  "TagSet: #{name}"
end

Protected Instance Methods

definition() click to toggle source
# File lib/microstation/tag_set.rb, line 347
def definition
  @definition ||= Definition.new(self)
end
find_tagset_instances_not_called?() click to toggle source
# File lib/microstation/tag_set.rb, line 356
def find_tagset_instances_not_called?
  !drawing.find_tagset_instances_called?
end
reset() click to toggle source
# File lib/microstation/tag_set.rb, line 351
def reset
  @tag_definitions = nil
end