aboutsummaryrefslogtreecommitdiffstats
path: root/lib/arel/collectors/sql_string.rb
blob: 1b2ff21b183030888ca27f0a746b67b4e0e4a8e8 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
module Arel
  module Collectors
    class SQLString
      def initialize
        @str = ''
      end

      def value
        @str
      end

      def << str
        @str << str
        self
      end

      def start;  self; end
      def finish; self; end

      def add_bind bind
        self << bind
        self
      end
    end
  end
end