Sha256: e3a7a9036a2c60fafebe297e7b1c9d7d158f3c7c9575efda982ccbee4b618add

Contents?: true

Size: 630 Bytes

Versions: 3

Compression:

Stored size: 630 Bytes

Contents

require_relative 'expressions'

module RailsServersideDatatables

  def if_then( test_expr, comparison_value, then_expr, else_expr )
    IfThen.new( test_expr, comparison_value, then_expr, else_expr )
  end

  def not_null( first, *rest )
    FirstNotNull.new( first, *rest )
  end

  def text_cast( expression )
    CastToText.new( expression )
  end

  def num_cast( expression )
    CastToNumeric.new( expression )
  end

  def num_op( a, op, b )
    NumOp.new( a, op, b )
  end

  def expr_alias( expression, name )
    ExpressionAlias.new( expression, name )
  end

  def raw_expr( expr )
    ExprTreeNode.raw expr
  end

end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
rails_serverside_datatables-0.1.3 lib/rails_serverside_datatables/expression_functions.rb
rails_serverside_datatables-0.1.2 lib/rails_serverside_datatables/expression_functions.rb
rails_serverside_datatables-0.1.1 lib/rails_serverside_datatables/expression_functions.rb