class Dusen::Description
Attributes
syntax[R]
Public Class Methods
new(syntax)
click to toggle source
# File lib/dusen/description.rb, line 9 def initialize(syntax) @syntax = syntax end
parse_syntax(syntax, &dsl)
click to toggle source
# File lib/dusen/description.rb, line 17 def self.parse_syntax(syntax, &dsl) description = new(syntax) description.instance_eval(&dsl) description.syntax end
Public Instance Methods
search_by(field, &scoper)
click to toggle source
# File lib/dusen/description.rb, line 13 def search_by(field, &scoper) @syntax.learn_field(field, &scoper) end