Class: ApiQueryLanguage::ActiveRecord::Fields::MappingToColumn::Mapping

Inherits:
Data
  • Object
show all
Defined in:
lib/api_query_language/active_record/fields/mapping_to_column.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(column:, relation:, value_transform: nil, allowed_values: nil) ⇒ Mapping

Returns a new instance of Mapping.



6
7
8
# File 'lib/api_query_language/active_record/fields/mapping_to_column.rb', line 6

def initialize(column:, relation:, value_transform: nil, allowed_values: nil)
  super
end

Instance Attribute Details

#allowed_valuesObject (readonly)

Returns the value of attribute allowed_values

Returns:

  • (Object)

    the current value of allowed_values



5
6
7
# File 'lib/api_query_language/active_record/fields/mapping_to_column.rb', line 5

def allowed_values
  @allowed_values
end

#columnObject (readonly)

Returns the value of attribute column

Returns:

  • (Object)

    the current value of column



5
6
7
# File 'lib/api_query_language/active_record/fields/mapping_to_column.rb', line 5

def column
  @column
end

#relationObject (readonly)

Returns the value of attribute relation

Returns:

  • (Object)

    the current value of relation



5
6
7
# File 'lib/api_query_language/active_record/fields/mapping_to_column.rb', line 5

def relation
  @relation
end

#value_transformObject (readonly)

Returns the value of attribute value_transform

Returns:

  • (Object)

    the current value of value_transform



5
6
7
# File 'lib/api_query_language/active_record/fields/mapping_to_column.rb', line 5

def value_transform
  @value_transform
end