Class: Elf::Value::Unknown
- Inherits:
-
Object
- Object
- Elf::Value::Unknown
- Defined in:
- lib/elf/value.rb
Overview
Class for unknown values
This class is used to provide a way to access at least basic data for values that are not known but are known valid (like OS- or CPU-specific types for files, sections and symbols).
It mimics the basis of a Value but is custom-filled by the using code.
Direct Known Subclasses
Instance Attribute Summary collapse
-
#desc ⇒ Object
(also: #to_s)
readonly
Returns the value of attribute desc.
-
#val ⇒ Object
(also: #to_i)
readonly
Returns the value of attribute val.
Instance Method Summary collapse
-
#initialize(val, desc) ⇒ Unknown
constructor
A new instance of Unknown.
Constructor Details
#initialize(val, desc) ⇒ Unknown
Returns a new instance of Unknown.
118 119 120 121 |
# File 'lib/elf/value.rb', line 118 def initialize(val, desc) @val = val @desc = desc end |
Instance Attribute Details
#desc ⇒ Object (readonly) Also known as: to_s
Returns the value of attribute desc.
123 124 125 |
# File 'lib/elf/value.rb', line 123 def desc @desc end |
#val ⇒ Object (readonly) Also known as: to_i
Returns the value of attribute val.
123 124 125 |
# File 'lib/elf/value.rb', line 123 def val @val end |