Sha256: 4d6dc18a196f8cc6850720de314b4cc70bc62f073d0c4eff7dc6e174e7a8d073
Contents?: true
Size: 384 Bytes
Versions: 2
Compression:
Stored size: 384 Bytes
Contents
module Ryodo class Parser def initialize @rules = Ryodo::RuleSet.new end def build_query(domain) domain.split(".").reverse end def parse(domain) @rules.match build_query(domain) end class << self def run(domain) instance.parse(domain) end def instance @instance ||= new end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
ryodo-0.3.2 | lib/ryodo/parser.rb |
ryodo-0.3.1 | lib/ryodo/parser.rb |