Class: ActiveMocker::SchemaReader Private
- Inherits:
-
Object
- Object
- ActiveMocker::SchemaReader
- Defined in:
- lib/active_mocker/schema_reader.rb
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Instance Attribute Summary collapse
- #cache_file ⇒ Object readonly private
- #cache_tables ⇒ Object readonly private
- #clear_cache ⇒ Object readonly private
- #file_reader ⇒ Object readonly private
- #migration_dir ⇒ Object readonly private
- #model_name ⇒ Object readonly private
- #schema_file ⇒ Object readonly private
- #schema_version ⇒ Object readonly private
- #tables ⇒ Object readonly private
Instance Method Summary collapse
-
#initialize(options = {}) ⇒ SchemaReader
constructor
private
A new instance of SchemaReader.
- #search(model_name) ⇒ Object private
Constructor Details
#initialize(options = {}) ⇒ SchemaReader
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of SchemaReader.
16 17 18 19 20 |
# File 'lib/active_mocker/schema_reader.rb', line 16 def initialize(={}) @file_reader = [:file_reader] ||= FileReader @schema_file = [:schema_file] end |
Instance Attribute Details
#cache_file ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
6 7 8 |
# File 'lib/active_mocker/schema_reader.rb', line 6 def cache_file @cache_file end |
#cache_tables ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
6 7 8 |
# File 'lib/active_mocker/schema_reader.rb', line 6 def cache_tables @cache_tables end |
#clear_cache ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
6 7 8 |
# File 'lib/active_mocker/schema_reader.rb', line 6 def clear_cache @clear_cache end |
#file_reader ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
6 7 8 |
# File 'lib/active_mocker/schema_reader.rb', line 6 def file_reader @file_reader end |
#migration_dir ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
6 7 8 |
# File 'lib/active_mocker/schema_reader.rb', line 6 def migration_dir @migration_dir end |
#model_name ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
6 7 8 |
# File 'lib/active_mocker/schema_reader.rb', line 6 def model_name @model_name end |
#schema_file ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
6 7 8 |
# File 'lib/active_mocker/schema_reader.rb', line 6 def schema_file @schema_file end |
#schema_version ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
6 7 8 |
# File 'lib/active_mocker/schema_reader.rb', line 6 def schema_version @schema_version end |
#tables ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
6 7 8 |
# File 'lib/active_mocker/schema_reader.rb', line 6 def tables @tables end |
Instance Method Details
#search(model_name) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
22 23 24 25 26 |
# File 'lib/active_mocker/schema_reader.rb', line 22 def search(model_name) @model_name = model_name load_table @tables end |