DiffSet
DiffSet contains a collection of data structures optimized to perform partial set subtractions.
DiffSet::RandomSetProduces a randomized set differenceDiffSet::PrioritySetProduces an ordered set differenceDiffSet::PairwiseRandomSetPresents a random set difference as a list of pairsDiffSet::PairwisePrioritySetPresents an ordered set difference as a list of pairs
Installation
- Install Boost:
OS X:
brew update && brew install boostUbuntu:
sudo apt-get update && sudo apt-get install libboost-all-dev
Add this line to your application's Gemfile:
gem 'diff_set'And then execute:
bundle
To install rice Ruby must be compiled with shared libraries enabled
rvm:
rvm reinstall [version] -- --enable-sharedrbenv:
CONFIGURE_OPTS="--enable-shared" rbenv install [version]
Usage
The API is pretty straightforward, and the specs have examples.
Testing
Run the specs with rake
Contributing
- Fork it ( http://github.com/parrish/diff_set/fork )
- Create your feature branch (
git checkout -b my-new-feature) - Commit your changes (
git commit -am 'Add some feature') - Push to the branch (
git push origin my-new-feature) - Create new Pull Request