Class: GoogleSpreadsheet::Record
- Inherits:
-
Hash
- Object
- Hash
- GoogleSpreadsheet::Record
- Defined in:
- lib/google_spreadsheet.rb
Overview
Use GoogleSpreadsheet::Table#records to get GoogleSpreadsheet::Record objects.
Instance Method Summary collapse
-
#initialize(session, entry) ⇒ Record
constructor
:nodoc:.
-
#inspect ⇒ Object
:nodoc:.
Constructor Details
#initialize(session, entry) ⇒ Record
:nodoc:
484 485 486 487 488 489 |
# File 'lib/google_spreadsheet.rb', line 484 def initialize(session, entry) #:nodoc: @session = session for field in entry.search("gs:field") self[as_utf8(field["name"])] = as_utf8(field.inner_text) end end |
Instance Method Details
#inspect ⇒ Object
:nodoc:
491 492 493 494 |
# File 'lib/google_spreadsheet.rb', line 491 def inspect #:nodoc: content = self.map(){ |k, v| "%p => %p" % [k, v] }.join(", ") return "\#<%p:{%s}>" % [self.class, content] end |