Class: Torque::PostgreSQL::Arel::Nodes::Cast
- Inherits:
-
Arel::Nodes::Binary
- Object
- Arel::Nodes::Binary
- Torque::PostgreSQL::Arel::Nodes::Cast
- Includes:
- Arel::AliasPredication, Arel::Expressions, Arel::Math, Arel::OrderPredications, Arel::Predications
- Defined in:
- lib/torque/postgresql/arel/nodes.rb
Instance Method Summary collapse
-
#initialize(left, right, array = false) ⇒ Cast
constructor
A new instance of Cast.
Constructor Details
#initialize(left, right, array = false) ⇒ Cast
Returns a new instance of Cast.
15 16 17 18 19 |
# File 'lib/torque/postgresql/arel/nodes.rb', line 15 def initialize(left, right, array = false) right = right.to_s right << '[]' if array super left, right end |