Class: AcademicBenchmarks::Standards::Document
- Inherits:
-
Object
- Object
- AcademicBenchmarks::Standards::Document
- Includes:
- InstVarsToHash
- Defined in:
- lib/academic_benchmarks/standards/document.rb
Instance Attribute Summary collapse
-
#guid ⇒ Object
Returns the value of attribute guid.
-
#title ⇒ Object
Returns the value of attribute title.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(title:, guid:) ⇒ Document
constructor
A new instance of Document.
Methods included from InstVarsToHash
Constructor Details
#initialize(title:, guid:) ⇒ Document
Returns a new instance of Document.
14 15 16 17 |
# File 'lib/academic_benchmarks/standards/document.rb', line 14 def initialize(title:, guid:) @title = title @guid = guid end |
Instance Attribute Details
#guid ⇒ Object
Returns the value of attribute guid.
8 9 10 |
# File 'lib/academic_benchmarks/standards/document.rb', line 8 def guid @guid end |
#title ⇒ Object
Returns the value of attribute title.
8 9 10 |
# File 'lib/academic_benchmarks/standards/document.rb', line 8 def title @title end |
Class Method Details
.from_hash(hash) ⇒ Object
10 11 12 |
# File 'lib/academic_benchmarks/standards/document.rb', line 10 def self.from_hash(hash) self.new(title: hash["title"], guid: hash["guid"]) end |