Module: Torque::PostgreSQL::BoundSchemaReflection
- Defined in:
- lib/torque/postgresql/schema_cache/bound_schema_reflection.rb
Instance Method Summary collapse
- #add_model_name(table_name, model) ⇒ Object
- #associations(table_name) ⇒ Object
- #dependencies(table_name) ⇒ Object
- #lookup_model(table_name, scoped_class = '') ⇒ Object
Instance Method Details
#add_model_name(table_name, model) ⇒ Object
6 7 8 9 |
# File 'lib/torque/postgresql/schema_cache/bound_schema_reflection.rb', line 6 def add_model_name(table_name, model) source = defined?(@pool) ? @pool : @connection @schema_reflection.add_model_name(source, table_name, model) end |
#associations(table_name) ⇒ Object
16 17 18 19 |
# File 'lib/torque/postgresql/schema_cache/bound_schema_reflection.rb', line 16 def associations(table_name) source = defined?(@pool) ? @pool : @connection @schema_reflection.associations(source, table_name) end |
#dependencies(table_name) ⇒ Object
11 12 13 14 |
# File 'lib/torque/postgresql/schema_cache/bound_schema_reflection.rb', line 11 def dependencies(table_name) source = defined?(@pool) ? @pool : @connection @schema_reflection.dependencies(source, table_name) end |
#lookup_model(table_name, scoped_class = '') ⇒ Object
21 22 23 24 |
# File 'lib/torque/postgresql/schema_cache/bound_schema_reflection.rb', line 21 def lookup_model(table_name, scoped_class = '') source = defined?(@pool) ? @pool : @connection @schema_reflection.lookup_model(source, table_name, scoped_class) end |