Class: TriCoreDB::StreamEntry
- Inherits:
-
Struct
- Object
- Struct
- TriCoreDB::StreamEntry
- Defined in:
- lib/tricoredb/response.rb
Overview
One entry of a cache stream.
Instance Attribute Summary collapse
-
#fields ⇒ Object
Returns the value of attribute fields.
-
#id ⇒ Object
Returns the value of attribute id.
Instance Method Summary collapse
-
#text ⇒ Hash{String => String}
Fields decoded as UTF-8, for the all-text case.
Instance Attribute Details
#fields ⇒ Object
Returns the value of attribute fields
39 40 41 |
# File 'lib/tricoredb/response.rb', line 39 def fields @fields end |
#id ⇒ Object
Returns the value of attribute id
39 40 41 |
# File 'lib/tricoredb/response.rb', line 39 def id @id end |
Instance Method Details
#text ⇒ Hash{String => String}
Returns fields decoded as UTF-8, for the all-text case.
41 42 43 |
# File 'lib/tricoredb/response.rb', line 41 def text fields.to_h { |f, v| [f.dup.force_encoding(Encoding::UTF_8), v.dup.force_encoding(Encoding::UTF_8)] } end |