Class: Hecks::QuerySpecification::Common::WhereClause

Inherits:
Struct
  • Object
show all
Defined in:
lib/hecks/query_specification/common/where_clause.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#fieldObject

Returns the value of attribute field

Returns:

  • (Object)

    the current value of field



4
5
6
# File 'lib/hecks/query_specification/common/where_clause.rb', line 4

def field
  @field
end

#opObject

Returns the value of attribute op

Returns:

  • (Object)

    the current value of op



4
5
6
# File 'lib/hecks/query_specification/common/where_clause.rb', line 4

def op
  @op
end

#valueObject

Returns the value of attribute value

Returns:

  • (Object)

    the current value of value



4
5
6
# File 'lib/hecks/query_specification/common/where_clause.rb', line 4

def value
  @value
end

Instance Method Details

#to_hObject



5
# File 'lib/hecks/query_specification/common/where_clause.rb', line 5

def to_h = { field: field.to_s, op: op.to_s, value: QuerySpecification.render_value(value) }