Class: Boundy::Formatters::Sql::Domain::Finite
- Inherits:
-
Object
- Object
- Boundy::Formatters::Sql::Domain::Finite
- Includes:
- Boundy::Formatter::Sql::Domain::Plugin
- Defined in:
- lib/boundy/formatters/sql/domain/finite.rb
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(domain, name) ⇒ Finite
constructor
A new instance of Finite.
- #to_s ⇒ Object
Methods included from Boundy::Formatter::Sql::Domain::Plugin
Constructor Details
#initialize(domain, name) ⇒ Finite
Returns a new instance of Finite.
13 14 15 16 17 |
# File 'lib/boundy/formatters/sql/domain/finite.rb', line 13 def initialize(domain, name) @name = name @from_formatter = Boundy::Formatter::Sql.new(domain.from, name) @to_formatter = Boundy::Formatter::Sql.new(domain.to, name) end |
Class Method Details
Instance Method Details
#to_s ⇒ Object
19 20 21 |
# File 'lib/boundy/formatters/sql/domain/finite.rb', line 19 def to_s "#{@name} >= '#{@from_formatter.to_s}' AND #{@name} <= '#{@to_formatter.to_s}'" end |