Class: MiniCSS::AST::Number
- Inherits:
-
Object
- Object
- MiniCSS::AST::Number
- Defined in:
- lib/minicss/ast/number.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#raw ⇒ Object
Returns the value of attribute raw.
-
#sign ⇒ Object
Returns the value of attribute sign.
-
#type ⇒ Object
Returns the value of attribute type.
-
#value ⇒ Object
Returns the value of attribute value.
Instance Method Summary collapse
-
#initialize(css) ⇒ Number
constructor
A new instance of Number.
Constructor Details
#initialize(css) ⇒ Number
Returns a new instance of Number.
8 9 10 11 |
# File 'lib/minicss/ast/number.rb', line 8 def initialize(css) @raw = css.literal @value, @type, @sign = css.opts.slice(:value, :type, :sign_character).values end |
Instance Attribute Details
#raw ⇒ Object
Returns the value of attribute raw.
6 7 8 |
# File 'lib/minicss/ast/number.rb', line 6 def raw @raw end |
#sign ⇒ Object
Returns the value of attribute sign.
6 7 8 |
# File 'lib/minicss/ast/number.rb', line 6 def sign @sign end |
#type ⇒ Object
Returns the value of attribute type.
6 7 8 |
# File 'lib/minicss/ast/number.rb', line 6 def type @type end |
#value ⇒ Object
Returns the value of attribute value.
6 7 8 |
# File 'lib/minicss/ast/number.rb', line 6 def value @value end |