Module: ForceSchema
- Defined in:
- lib/force_schema.rb,
lib/force_schema/schema.rb,
lib/force_schema/version.rb,
lib/force_schema/registry.rb
Defined Under Namespace
Classes: Registry, Schema
Constant Summary
collapse
- VERSION =
"0.1.0"
Instance Method Summary
collapse
Instance Method Details
#enforced_schema ⇒ Object
18
19
20
|
# File 'lib/force_schema.rb', line 18
def enforced_schema
Registry.instance[name] ||= Schema.new self
end
|
#force_schema(create_table_options = {}, &blk) ⇒ Object
12
13
14
15
16
|
# File 'lib/force_schema.rb', line 12
def force_schema(create_table_options = {}, &blk)
enforced_schema.create_table_options = create_table_options
::Blockenspiel.invoke blk, enforced_schema
enforced_schema
end
|
#force_schema! ⇒ Object
8
9
10
|
# File 'lib/force_schema.rb', line 8
def force_schema!
enforced_schema.run
end
|