Class: DB::Identifier
- Inherits:
-
Array
- Object
- Array
- DB::Identifier
- Defined in:
- lib/db/query.rb
Overview
Represents one or more identifiers for databases, tables or columns.
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.coerce(name_or_identifier) ⇒ Object
9 10 11 12 13 14 15 16 17 18 19 20 |
# File 'lib/db/query.rb', line 9 def self.coerce(name_or_identifier) case name_or_identifier when Identifier name_or_identifier when Array self.new(name_or_identifier) when Symbol self[name_or_identifier] else self[name_or_identifier.to_sym] end end |
Instance Method Details
#append_to(query) ⇒ Object
22 23 24 |
# File 'lib/db/query.rb', line 22 def append_to(query) query.identifier(self) end |