Class: PGExaminer::Result::Item
- Defined in:
- lib/pg_examiner/result/item.rb
Direct Known Subclasses
Column, Constraint, Extension, Function, Index, Language, Schema, Sequence, Table, Trigger
Instance Attribute Summary collapse
-
#parent ⇒ Object
readonly
Returns the value of attribute parent.
-
#result ⇒ Object
readonly
Returns the value of attribute result.
-
#row ⇒ Object
readonly
Returns the value of attribute row.
Instance Method Summary collapse
-
#initialize(result, row, parent = nil) ⇒ Item
constructor
A new instance of Item.
- #inspect ⇒ Object
- #name ⇒ Object
- #oid ⇒ Object
Methods inherited from Base
#==, #diff, #diffable_attrs, #diffable_lists, #diffable_methods
Constructor Details
#initialize(result, row, parent = nil) ⇒ Item
Returns a new instance of Item.
8 9 10 |
# File 'lib/pg_examiner/result/item.rb', line 8 def initialize(result, row, parent = nil) @result, @row, @parent = result, row, parent end |
Instance Attribute Details
#parent ⇒ Object (readonly)
Returns the value of attribute parent.
6 7 8 |
# File 'lib/pg_examiner/result/item.rb', line 6 def parent @parent end |
#result ⇒ Object (readonly)
Returns the value of attribute result.
6 7 8 |
# File 'lib/pg_examiner/result/item.rb', line 6 def result @result end |
#row ⇒ Object (readonly)
Returns the value of attribute row.
6 7 8 |
# File 'lib/pg_examiner/result/item.rb', line 6 def row @row end |
Instance Method Details
#inspect ⇒ Object
20 21 22 |
# File 'lib/pg_examiner/result/item.rb', line 20 def inspect "#<#{self.class} @row=#{@row.inspect}>" end |
#name ⇒ Object
16 17 18 |
# File 'lib/pg_examiner/result/item.rb', line 16 def name @row['name'] end |
#oid ⇒ Object
12 13 14 |
# File 'lib/pg_examiner/result/item.rb', line 12 def oid @row['oid'] end |