module Ronin::SQL::Operators
Methods for creating SQL
expressions.
@api public
Public Instance Methods
Logical negate.
@return [UnaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 299 def ! UnaryExpr.new(:!,self) end
Not equal to.
@return [BinaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 179 def !=(other) BinaryExpr.new(self,:!=,other) end
Modulus.
@return [BinaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 59 def %(other) BinaryExpr.new(self,:%,other) end
Bit-wise ‘AND`.
@return [BinaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 109 def &(other) BinaryExpr.new(self,:&,other) end
Multiplication.
@return [BinaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 39 def *(other) BinaryExpr.new(self,:*,other) end
Addition.
@return [BinaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 69 def +(other) BinaryExpr.new(self,:+,other) end
Unary plus.
@return [UnaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 279 def +@ UnaryExpr.new(:+,self) end
Subtraction.
@return [BinaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 79 def -(other) BinaryExpr.new(self,:-,other) end
Unary minus.
@return [UnaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 269 def -@ UnaryExpr.new(:-,self) end
Division.
@return [BinaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 49 def /(other) BinaryExpr.new(self,:/,other) end
Less than.
@return [BinaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 129 def <(other) BinaryExpr.new(self,:<,other) end
Bit-wise left shift.
@return [BinaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 89 def <<(other) BinaryExpr.new(self,:<<,other) end
Less than or equal to.
@return [BinaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 139 def <=(other) BinaryExpr.new(self,:<=,other) end
Equal to.
@return [BinaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 169 def ==(other) BinaryExpr.new(self,:"=",other) end
Greater than.
@return [BinaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 149 def >(other) BinaryExpr.new(self,:>,other) end
Greater than or equal to.
@return [BinaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 159 def >=(other) BinaryExpr.new(self,:>=,other) end
Bit-wise right shift.
@return [BinaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 99 def >>(other) BinaryExpr.new(self,:>>,other) end
‘AND`.
@return [BinaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 319 def and(other) BinaryExpr.new(self,:AND,other) end
Alias.
@return [BinaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 189 def as(name) BinaryExpr.new(self,:AS,name) end
‘GLOB` comparison.
@return [BinaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 229 def glob(other) BinaryExpr.new(self,:GLOB,other) end
‘REGEXP` comparison.
@return [BinaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 259 def in(other) BinaryExpr.new(self,:IN,other) end
‘IS` comparison.
@return [BinaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 199 def is(other) BinaryExpr.new(self,:IS,other) end
‘IS NOT` comparison.
@return [BinaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 209 def is_not(other) BinaryExpr.new(self,[:IS, :NOT],other) end
‘LIKE` comparison.
@return [BinaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 219 def like(other) BinaryExpr.new(self,:LIKE,other) end
‘MATCH` comparison.
@return [BinaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 239 def match(other) BinaryExpr.new(self,:MATCH,other) end
Logical ‘NOT`.
@return [UnaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 309 def not UnaryExpr.new(:NOT,self) end
‘OR`.
@return [BinaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 329 def or(other) BinaryExpr.new(self,:OR,other) end
‘REGEXP` comparison.
@return [BinaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 249 def regexp(other) BinaryExpr.new(self,:REGEXP,other) end
Bit-wise ‘OR`.
@return [BinaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 119 def |(other) BinaryExpr.new(self,:|,other) end
Bit-wise negate.
@return [UnaryExpr]
The new binary expression.
# File lib/ronin/sql/operators.rb, line 289 def ~ UnaryExpr.new(:~,self) end