Class: CSSPool::Terms::Number

Inherits:
Ident show all
Defined in:
lib/csspool/terms/number.rb

Instance Attribute Summary collapse

Attributes inherited from Ident

#operator, #parse_location, #value

Attributes inherited from Node

#inner_end_pos, #inner_start_pos, #outer_end_pos, #outer_start_pos

Instance Method Summary collapse

Methods inherited from Node

#==, #accept, #children, #each, #hash, #to_css, #to_minified_css

Constructor Details

#initialize(value, unary_operator = nil, type = nil, operator = nil, parse_location = {}) ⇒ Number

Returns a new instance of Number.



7
8
9
10
11
# File 'lib/csspool/terms/number.rb', line 7

def initialize value, unary_operator = nil, type = nil, operator = nil, parse_location = {}
  @type     = type
  @unary_operator = unary_operator
  super(value, operator, parse_location)
end

Instance Attribute Details

#typeObject

Returns the value of attribute type.



4
5
6
# File 'lib/csspool/terms/number.rb', line 4

def type
  @type
end

#unary_operatorObject

Returns the value of attribute unary_operator.



5
6
7
# File 'lib/csspool/terms/number.rb', line 5

def unary_operator
  @unary_operator
end