Class: Danica::Wrapper::Group
- Inherits:
-
Object
- Object
- Danica::Wrapper::Group
- Includes:
- BaseOperations, Common
- Defined in:
- lib/danica/wrapper/group.rb
Instance Attribute Summary collapse
-
#value ⇒ Object
Returns the value of attribute value.
Instance Method Summary collapse
- #==(other) ⇒ Object
-
#initialize(value) ⇒ Group
constructor
A new instance of Group.
- #to_gnu(**options) ⇒ Object
- #to_tex(**options) ⇒ Object
Methods included from BaseOperations
Methods included from Common
#content, #formatted, #gnu, #tex, #to, #to_f, #valued?
Constructor Details
#initialize(value) ⇒ Group
Returns a new instance of Group.
15 16 17 |
# File 'lib/danica/wrapper/group.rb', line 15 def initialize(value) @value = wrap_value(value) end |
Instance Attribute Details
#value ⇒ Object
Returns the value of attribute value.
8 9 10 |
# File 'lib/danica/wrapper/group.rb', line 8 def value @value end |
Instance Method Details
#==(other) ⇒ Object
27 28 29 30 31 |
# File 'lib/danica/wrapper/group.rb', line 27 def ==(other) return value == other unless other.is_a?(self.class) value == other.value end |
#to_gnu(**options) ⇒ Object
23 24 25 |
# File 'lib/danica/wrapper/group.rb', line 23 def to_gnu(**) "(#{value.to_gnu()})" end |
#to_tex(**options) ⇒ Object
19 20 21 |
# File 'lib/danica/wrapper/group.rb', line 19 def to_tex(**) "\\left(#{value.to_tex()}\\right)" end |