aboutsummaryrefslogtreecommitdiffstats
path: root/lib/arel/relations
diff options
context:
space:
mode:
authorNick Kallen <nkallen@nick-kallens-computer-2.local>2008-05-04 18:52:48 -0700
committerNick Kallen <nkallen@nick-kallens-computer-2.local>2008-05-04 18:52:48 -0700
commit4a313bb478765cbc5007aac5097291dabd4628c7 (patch)
tree9514e8218052435dfb506da5c3f679227b17e10f /lib/arel/relations
parent542a14c2580469eebdf1d281383096ea985ee11b (diff)
downloadrails-4a313bb478765cbc5007aac5097291dabd4628c7.tar.gz
rails-4a313bb478765cbc5007aac5097291dabd4628c7.tar.bz2
rails-4a313bb478765cbc5007aac5097291dabd4628c7.zip
missing file
Diffstat (limited to 'lib/arel/relations')
-rw-r--r--lib/arel/relations/recursion.rb17
1 files changed, 17 insertions, 0 deletions
diff --git a/lib/arel/relations/recursion.rb b/lib/arel/relations/recursion.rb
new file mode 100644
index 0000000000..2c6024dc30
--- /dev/null
+++ b/lib/arel/relations/recursion.rb
@@ -0,0 +1,17 @@
+module Arel
+ module Recursion
+ module BaseCase
+ def table
+ self
+ end
+
+ def relation_for(attribute)
+ self[attribute] and self
+ end
+
+ def table_sql(formatter = Sql::TableReference.new(self))
+ formatter.table self
+ end
+ end
+ end
+end \ No newline at end of file