aboutsummaryrefslogtreecommitdiffstats
path: root/lib/arel/nodes/table_alias.rb
diff options
context:
space:
mode:
authorAaron Patterson <aaron.patterson@gmail.com>2010-11-29 15:17:59 -0800
committerAaron Patterson <aaron.patterson@gmail.com>2010-11-29 15:17:59 -0800
commit039947e5ac9c9a2e19282e3548ab7a1f30cbbc3a (patch)
tree8d9beb8dd6d04f1825d2b67e74c7a880f28ef504 /lib/arel/nodes/table_alias.rb
parent963ca860d579a507effbe818da0c89bf443f33c9 (diff)
downloadrails-039947e5ac9c9a2e19282e3548ab7a1f30cbbc3a.tar.gz
rails-039947e5ac9c9a2e19282e3548ab7a1f30cbbc3a.tar.bz2
rails-039947e5ac9c9a2e19282e3548ab7a1f30cbbc3a.zip
updating nodes and depth first visitor
Diffstat (limited to 'lib/arel/nodes/table_alias.rb')
-rw-r--r--lib/arel/nodes/table_alias.rb10
1 files changed, 3 insertions, 7 deletions
diff --git a/lib/arel/nodes/table_alias.rb b/lib/arel/nodes/table_alias.rb
index 60da7b19f3..723b025883 100644
--- a/lib/arel/nodes/table_alias.rb
+++ b/lib/arel/nodes/table_alias.rb
@@ -1,14 +1,10 @@
module Arel
module Nodes
- class TableAlias
- attr_reader :name, :relation
+ class TableAlias < Arel::Nodes::Binary
+ alias :name :left
+ alias :relation :right
alias :table_alias :name
- def initialize name, relation
- @name = name
- @relation = relation
- end
-
def [] name
Attribute.new self, name
end