Module: TTK::Strategies::Composite::Ordered

Defined in:
lib/ttk/strategies/Composite.rb

Class Method Summary collapse

Class Method Details

.included(aClass) ⇒ Object



156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
# File 'lib/ttk/strategies/Composite.rb', line 156

def self.included ( aClass )

  aClass.module_eval do

    def new_symtbl
      if @contents.empty?
        @symtbl.class.new(@symtbl)
      else
        @symtbl.class.new(@contents.last.symtbl)
      end
    end
    protected :new_symtbl

  end

end