Class: MiniCSS::AST::Function

Inherits:
Object
  • Object
show all
Defined in:
lib/minicss/ast/function.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(func) ⇒ Function

Returns a new instance of Function.



8
9
10
11
12
# File 'lib/minicss/ast/function.rb', line 8

def initialize(func)
  @raw_name = func.name.literal
  @name = raw_name.strip.gsub(/\($/, "")
  @value = func.value.map { AST.convert(it) }
end

Instance Attribute Details

#nameObject

Returns the value of attribute name.



6
7
8
# File 'lib/minicss/ast/function.rb', line 6

def name
  @name
end

#raw_nameObject

Returns the value of attribute raw_name.



6
7
8
# File 'lib/minicss/ast/function.rb', line 6

def raw_name
  @raw_name
end

#valueObject

Returns the value of attribute value.



6
7
8
# File 'lib/minicss/ast/function.rb', line 6

def value
  @value
end