Class: Choosy::Printing::FormattingElement
- Inherits:
-
Object
- Object
- Choosy::Printing::FormattingElement
- Defined in:
- lib/choosy/printing/formatting_element.rb
Instance Attribute Summary collapse
-
#kind ⇒ Object
readonly
Returns the value of attribute kind.
-
#styles ⇒ Object
readonly
Returns the value of attribute styles.
-
#value ⇒ Object
readonly
Returns the value of attribute value.
Instance Method Summary collapse
- #header? ⇒ Boolean
-
#initialize(kind, value, styles) ⇒ FormattingElement
constructor
A new instance of FormattingElement.
Constructor Details
#initialize(kind, value, styles) ⇒ FormattingElement
Returns a new instance of FormattingElement.
5 6 7 8 9 |
# File 'lib/choosy/printing/formatting_element.rb', line 5 def initialize(kind, value, styles) @value = value @kind = kind @styles = styles end |
Instance Attribute Details
#kind ⇒ Object (readonly)
Returns the value of attribute kind.
3 4 5 |
# File 'lib/choosy/printing/formatting_element.rb', line 3 def kind @kind end |
#styles ⇒ Object (readonly)
Returns the value of attribute styles.
3 4 5 |
# File 'lib/choosy/printing/formatting_element.rb', line 3 def styles @styles end |
#value ⇒ Object (readonly)
Returns the value of attribute value.
3 4 5 |
# File 'lib/choosy/printing/formatting_element.rb', line 3 def value @value end |
Instance Method Details
#header? ⇒ Boolean
11 12 13 |
# File 'lib/choosy/printing/formatting_element.rb', line 11 def header? @kind == :header end |