Class: Squish::Leaf

Inherits:
Node
  • Object
show all
Defined in:
lib/squish.rb

Overview

Originally written by Aggelos Orfanakos

Instance Attribute Summary collapse

Attributes inherited from Node

#weight

Instance Method Summary collapse

Methods inherited from Node

#<=>

Constructor Details

#initialize(weight, data) ⇒ Leaf

Returns a new instance of Leaf.



346
347
348
349
# File 'lib/squish.rb', line 346

def initialize(weight, data)
  super(weight)
  @data = data
end

Instance Attribute Details

#dataObject (readonly)

:nodoc:



344
345
346
# File 'lib/squish.rb', line 344

def data
  @data
end