Sha256: a72ffb208dbc9ff030a468fd99ea46dddb9f8b0037d15e0fccc2611ea60227f8

Contents?: true

Size: 905 Bytes

Versions: 1

Compression:

Stored size: 905 Bytes

Contents

module Rtml::WidgetCore::WidgetAccessorInstanceMethods
  def widget_instances
    @widget_instances ||= []
  end

  delegate :class_widget_proxies, :class_widget_entry_points, :to => 'self.class'

  def singleton_widgets; (class << self; self; end).class_widgets ||= [] end
  def singleton_widget_proxies; (class << self; self; end).class_widget_proxies ||= [] end
  def singleton_widget_entry_points; (class << self; self; end).class_widget_entry_points ||= [] end

  def widgets; singleton_widgets + (self.class_widgets ||= []) end
  def widget_proxies; singleton_widget_proxies + (self.class_widget_proxies ||= []) end
  def widget_entry_points; singleton_widget_entry_points + (self.class_widget_entry_points ||= []) end

  alias class_widget_methods     class_widget_entry_points
  alias singleton_widget_methods singleton_widget_entry_points
  alias widget_methods           widget_entry_points
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
rtml-2.0.4 lib/rtml/widget_core/widget_accessor_instance_methods.rb