lib/veritas/sql/generator/relation.rb in veritas-sql-generator-0.0.5 vs lib/veritas/sql/generator/relation.rb in veritas-sql-generator-0.0.6
- old
+ new
@@ -28,16 +28,16 @@
# @return [Generator::Relation]
#
# @api private
def self.visit(relation)
klass = case relation
- when Veritas::Relation::Operation::Set then self::Set
- when Veritas::Relation::Operation::Binary then self::Binary
- when Veritas::Relation::Operation::Unary then self::Unary
- when Veritas::Relation::Base then self::Base
- else
- raise InvalidRelationError, "#{relation.class} is not a visitable relation"
+ when Veritas::Relation::Operation::Set then self::Set
+ when Veritas::Relation::Operation::Binary then self::Binary
+ when Veritas::Relation::Operation::Unary then self::Unary
+ when Veritas::Relation::Base then self::Base
+ else
+ raise InvalidRelationError, "#{relation.class} is not a visitable relation"
end
klass.new.visit(relation)
end
# Initialize a Generator
@@ -111,10 +111,10 @@
#
# @return [Boolean]
#
# @api public
def visited?
- !@name.nil?
+ ! @name.nil?
end
private
# Return the columns to use in a query