module Arel::FactoryMethods - arel-4.0.2 Documentation

# module Arel::FactoryMethods

Methods for creating various nodes

### Public Instance Methods

create_and(clauses) click to toggle source

    # File lib/arel/factory_methods.rb, line 25
    def create_and clauses
      Nodes::And.new clauses
    end

create_false() click to toggle source

    # File lib/arel/factory_methods.rb, line 9
    def create_false
      Arel::Nodes::False.new
    end

create_join(to, constraint = nil, klass = Nodes::InnerJoin) click to toggle source

    # File lib/arel/factory_methods.rb, line 17
    def create_join to, constraint = nil, klass = Nodes::InnerJoin
      klass.new(to, constraint)
    end

create_on(expr) click to toggle source

    # File lib/arel/factory_methods.rb, line 29
    def create_on expr
      Nodes::On.new expr
    end

create_string_join(to) click to toggle source

    # File lib/arel/factory_methods.rb, line 21
    def create_string_join to
      create_join to, nil, Nodes::StringJoin
    end

create_table_alias(relation, name) click to toggle source

    # File lib/arel/factory_methods.rb, line 13
    def create_table_alias relation, name
      Nodes::TableAlias.new(relation, name)
    end

create_true() click to toggle source

    # File lib/arel/factory_methods.rb, line 5
    def create_true
      Arel::Nodes::True.new
    end

grouping(expr) click to toggle source

    # File lib/arel/factory_methods.rb, line 33
    def grouping expr
      Nodes::Grouping.new expr
    end

lower(column) click to toggle source

Create a LOWER() function

    # File lib/arel/factory_methods.rb, line 39
    def lower column
      Nodes::NamedFunction.new 'LOWER', [column]
    end