Skip to content

dsh0416/prefix-machine

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

prefix-machine

A High Performance Prefix Match Machine for Ruby

require 'prefix-machine'

machine = PrefixMachine.new
machine << 'hello.'
machine << 'fork.ai.'
machine << 'fork.human.'
machine.match('hello.world') # => 'hello.'
machine.match('fork.ai.sdk') # => 'fork.ai.'
machine.match('fork.human.resources') # => 'fork.human.'
machine.match('refute') # => nil

About

A High Performance Prefix Match Machine for Ruby

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published