class Thinreports::Core::Shape::Base::Internal

@abstract

Attributes

format[R]
parent[R]
states[RW]
style[W]

Public Class Methods

new(parent, format) click to toggle source
# File lib/thinreports/core/shape/base/internal.rb, line 22
def initialize(parent, format)
  @parent = parent
  @format = format
  @states = {}
  @style = nil

  @finalized_attributes = nil
end

Private Class Methods

format_delegators(*args) click to toggle source
# File lib/thinreports/core/shape/base/internal.rb, line 12
def self.format_delegators(*args)
  def_delegators :format, *args
end

Public Instance Methods

copy(new_parent, &block) click to toggle source
# File lib/thinreports/core/shape/base/internal.rb, line 35
def copy(new_parent, &block)
  new_internal = self.class.new(new_parent, format)
  new_internal.style = style.copy
  new_internal.states = deep_copy(states)

  block.call(new_internal) if block_given?
  new_internal
end
style() click to toggle source
# File lib/thinreports/core/shape/base/internal.rb, line 31
def style
  raise NotImplementedError
end
type_of?() click to toggle source
# File lib/thinreports/core/shape/base/internal.rb, line 44
def type_of?
  raise NotImplementedError
end