Module: ActiveType::NoTable::ClassMethods
- Defined in:
- lib/active_type/no_table.rb,
lib/active_type/no_table.rb
Instance Method Summary collapse
- #_query_by_sql ⇒ Object
- #cached_find_by ⇒ Object
- #column_types ⇒ Object
- #columns ⇒ Object
- #connection ⇒ Object
- #destroy ⇒ Object
- #destroy_all ⇒ Object
- #find_by_sql ⇒ Object
- #primary_key ⇒ Object
- #schema_cache ⇒ Object
- #with_connection {|connection| ... } ⇒ Object
Instance Method Details
#_query_by_sql ⇒ Object
151 152 153 |
# File 'lib/active_type/no_table.rb', line 151 def _query_by_sql(*) [] end |
#cached_find_by ⇒ Object
155 156 157 |
# File 'lib/active_type/no_table.rb', line 155 def cached_find_by(*) nil end |
#column_types ⇒ Object
11 12 13 |
# File 'lib/active_type/no_table.rb', line 11 def column_types {} end |
#columns ⇒ Object
15 16 17 |
# File 'lib/active_type/no_table.rb', line 15 def columns [] end |
#connection ⇒ Object
131 132 133 |
# File 'lib/active_type/no_table.rb', line 131 def connection @connection ||= DummyConnection.new(nil) end |
#destroy ⇒ Object
23 24 25 |
# File 'lib/active_type/no_table.rb', line 23 def destroy(*) new end |
#destroy_all ⇒ Object
27 28 29 |
# File 'lib/active_type/no_table.rb', line 27 def destroy_all(*) [] end |
#find_by_sql ⇒ Object
31 32 33 |
# File 'lib/active_type/no_table.rb', line 31 def find_by_sql(*) [] end |
#primary_key ⇒ Object
19 20 21 |
# File 'lib/active_type/no_table.rb', line 19 def primary_key nil end |
#schema_cache ⇒ Object
159 160 161 |
# File 'lib/active_type/no_table.rb', line 159 def schema_cache DummySchemaCache.new end |
#with_connection {|connection| ... } ⇒ Object
135 136 137 |
# File 'lib/active_type/no_table.rb', line 135 def with_connection(**) yield(connection) end |