Class: ActiveRecord::ConnectionAdapters::PostgreSQL::TableDefinition
- Inherits:
-
TableDefinition
- Object
- TableDefinition
- ActiveRecord::ConnectionAdapters::PostgreSQL::TableDefinition
- Includes:
- ColumnMethods
- Defined in:
- lib/active_record/connection_adapters/postgresql/schema_definitions.rb
Instance Attribute Summary collapse
-
#unlogged ⇒ Object
readonly
Returns the value of attribute unlogged.
Attributes inherited from TableDefinition
#as, #check_constraints, #comment, #foreign_keys, #if_not_exists, #indexes, #name, #options, #temporary
Instance Method Summary collapse
-
#initialize ⇒ TableDefinition
constructor
A new instance of TableDefinition.
-
#new_column_definition(name, type, **options) ⇒ Object
:nodoc:.
Methods included from ColumnMethods
Methods inherited from TableDefinition
#[], #check_constraint, #column, #columns, #foreign_key, #index, #new_check_constraint_definition, #new_foreign_key_definition, #primary_keys, #references, #remove_column, #timestamps
Methods included from ColumnMethods
Constructor Details
#initialize ⇒ TableDefinition
Returns a new instance of TableDefinition.
197 198 199 200 |
# File 'lib/active_record/connection_adapters/postgresql/schema_definitions.rb', line 197 def initialize(*, **) super @unlogged = ActiveRecord::ConnectionAdapters::PostgreSQLAdapter.create_unlogged_tables end |
Instance Attribute Details
#unlogged ⇒ Object (readonly)
Returns the value of attribute unlogged.
195 196 197 |
# File 'lib/active_record/connection_adapters/postgresql/schema_definitions.rb', line 195 def unlogged @unlogged end |
Instance Method Details
#new_column_definition(name, type, **options) ⇒ Object
:nodoc:
202 203 204 205 206 207 208 209 |
# File 'lib/active_record/connection_adapters/postgresql/schema_definitions.rb', line 202 def new_column_definition(name, type, **) # :nodoc: case type when :virtual type = [:type] end super end |