Class: Epitome::Document
- Inherits:
-
Object
- Object
- Epitome::Document
- Defined in:
- lib/epitome/document.rb
Instance Attribute Summary collapse
-
#id ⇒ Object
readonly
Returns the value of attribute id.
-
#text ⇒ Object
readonly
Returns the value of attribute text.
Instance Method Summary collapse
-
#initialize(text) ⇒ Document
constructor
A new instance of Document.
Constructor Details
#initialize(text) ⇒ Document
Returns a new instance of Document.
8 9 10 11 |
# File 'lib/epitome/document.rb', line 8 def initialize(text) @id = SecureRandom.uuid @text = Scalpel.cut text end |
Instance Attribute Details
#id ⇒ Object (readonly)
Returns the value of attribute id.
6 7 8 |
# File 'lib/epitome/document.rb', line 6 def id @id end |
#text ⇒ Object (readonly)
Returns the value of attribute text.
7 8 9 |
# File 'lib/epitome/document.rb', line 7 def text @text end |