Class: ActiveRecord::ConnectionAdapters::IBM_DBAdapter::UniqueConstraintDefinition
- Inherits:
-
Struct
- Object
- Struct
- ActiveRecord::ConnectionAdapters::IBM_DBAdapter::UniqueConstraintDefinition
- Defined in:
- lib/active_record/connection_adapters/ibm_db_adapter.rb
Overview
end of class TableDefinition
Instance Attribute Summary collapse
-
#column ⇒ Object
Returns the value of attribute column.
-
#options ⇒ Object
Returns the value of attribute options.
-
#table_name ⇒ Object
Returns the value of attribute table_name.
Instance Method Summary collapse
- #deferrable ⇒ Object
- #defined_for?(name: nil, column: nil, **options) ⇒ Boolean
- #export_name_on_schema_dump? ⇒ Boolean
- #name ⇒ Object
- #using_index ⇒ Object
Instance Attribute Details
#column ⇒ Object
Returns the value of attribute column
894 895 896 |
# File 'lib/active_record/connection_adapters/ibm_db_adapter.rb', line 894 def column @column end |
#options ⇒ Object
Returns the value of attribute options
894 895 896 |
# File 'lib/active_record/connection_adapters/ibm_db_adapter.rb', line 894 def @options end |
#table_name ⇒ Object
Returns the value of attribute table_name
894 895 896 |
# File 'lib/active_record/connection_adapters/ibm_db_adapter.rb', line 894 def table_name @table_name end |
Instance Method Details
#deferrable ⇒ Object
899 900 901 |
# File 'lib/active_record/connection_adapters/ibm_db_adapter.rb', line 899 def deferrable [:deferrable] end |
#defined_for?(name: nil, column: nil, **options) ⇒ Boolean
911 912 913 914 915 |
# File 'lib/active_record/connection_adapters/ibm_db_adapter.rb', line 911 def defined_for?(name: nil, column: nil, **) (name.nil? || self.name == name.to_s) && (column.nil? || Array(self.column) == Array(column).map(&:to_s)) && .all? { |k, v| self.[k].to_s == v.to_s } end |
#export_name_on_schema_dump? ⇒ Boolean
907 908 909 |
# File 'lib/active_record/connection_adapters/ibm_db_adapter.rb', line 907 def export_name_on_schema_dump? !ActiveRecord::SchemaDumper.unique_ignore_pattern.match?(name) if name end |
#name ⇒ Object
895 896 897 |
# File 'lib/active_record/connection_adapters/ibm_db_adapter.rb', line 895 def name [:name] end |
#using_index ⇒ Object
903 904 905 |
# File 'lib/active_record/connection_adapters/ibm_db_adapter.rb', line 903 def using_index [:using_index] end |