Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up

Darts-clone.rb provides Ruby bindings for the Darts-clone.

License

NotificationsYou must be signed in to change notification settings

yoshoku/darts-clone.rb

Repository files navigation

Build StatusGem VersionBSD 2-Clause License

Darts-clone.rb provides Ruby bindings for theDarts-clone.

Installation

Add this line to your application's Gemfile:

gem'dartsclone'

And then execute:

$ bundle install

Or install it yourself as:

$ gem install dartsclone

Usage

require'dartsclone'da=DartsClone::DoubleArray.new# Construct a dictionary.keys=['abc','abcd','abcde','bcd','cde']da.build(keys)# Search for keys which match the prefix of given string.pda.common_prefix_search('abcde')# => [["abc", "abcd", "abcde"], [0, 1, 2]]# Search a key which matches a given string.pda.exact_match_search('abcd')# => 1# Dump the dictionary.da.save('foo.dat')# Load the dictionary.da.open('foo.dat')

Contributing

Bug reports and pull requests are welcome on GitHub athttps://github.com/yoshoku/darts-clone.rb.This project is intended to be a safe, welcoming space for collaboration,and contributors are expected to adhere to theContributor Covenant code of conduct.

License

The gem is available as open source under the terms of theBSD 2-clause License.Moreover, the gem includes the source code of Darts-clone.The License of Darts-clone can be found inCOPYING.md.

About

Darts-clone.rb provides Ruby bindings for the Darts-clone.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages


[8]ページ先頭

©2009-2025 Movatter.jp