{"id":15692024,"url":"https://github.com/jhawthorn/roaring-ruby","last_synced_at":"2025-04-30T15:23:05.430Z","repository":{"id":37791274,"uuid":"503164107","full_name":"jhawthorn/roaring-ruby","owner":"jhawthorn","description":"Roaring compressed bitmaps for Ruby","archived":false,"fork":false,"pushed_at":"2024-09-22T05:03:38.000Z","size":537,"stargazers_count":11,"open_issues_count":1,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-04-30T15:22:52.222Z","etag":null,"topics":["bitset","bitset-library","roaring-bitmaps"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jhawthorn.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-06-14T01:07:02.000Z","updated_at":"2025-04-08T16:25:42.000Z","dependencies_parsed_at":"2024-06-12T10:10:11.836Z","dependency_job_id":"13d2e781-8867-41cd-a9b0-14580880bf4a","html_url":"https://github.com/jhawthorn/roaring-ruby","commit_stats":{"total_commits":44,"total_committers":1,"mean_commits":44.0,"dds":0.0,"last_synced_commit":"99277052a8796243c07b3eb7fb8d5912581c378c"},"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jhawthorn%2Froaring-ruby","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jhawthorn%2Froaring-ruby/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jhawthorn%2Froaring-ruby/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jhawthorn%2Froaring-ruby/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jhawthorn","download_url":"https://codeload.github.com/jhawthorn/roaring-ruby/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251729814,"owners_count":21634294,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bitset","bitset-library","roaring-bitmaps"],"created_at":"2024-10-03T18:27:56.008Z","updated_at":"2025-04-30T15:23:05.410Z","avatar_url":"https://github.com/jhawthorn.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Roaring\n\n[Roaring Bitmaps](http://www.roaringbitmap.org/about/) are a compressed bitmap/bitset format/library. Think of it like a `Set` which can only hold (32-bit or 64-bit) `Integer`s, with much lower memory use and supporting fast set operations.\n\n## Installation\n\nInstall the gem and add to the application's Gemfile by executing:\n\n    $ bundle add roaring\n\n## Usage\n\n``` ruby\nrequire \"roaring\"\n\n# Bitmap32 can efficiently store a large range of 32-bit integers\nbitmap = Roaring::Bitmap32[1, 2, 3, 999]\nbitmap \u003c\u003c (2**32 - 1)\n\n# Bitmap64 can efficiently store a large range of 64-bit integers\nbitmap = Roaring::Bitmap64[1, 2, 3, 999]\nbitmap \u003c\u003c (2**32 + 1)\nbitmap \u003c\u003c (2**64 - 1)\n\n# Element access\nbitmap.each { }\nbitmap.first # =\u003e 1\nbitmap.min   # =\u003e 1\nbitmap.max   # =\u003e 18446744073709551615\nbitmap.last  # =\u003e 18446744073709551615\nbitmap[3]    # =\u003e 999\nbitmap.to_a  # =\u003e [1, 2, 3, 999, 4294967297, 18446744073709551615]\n\nb1 = Roaring::Bitmap64.new(200...500)\nb2 = Roaring::Bitmap64.new(100...1000)\n\n# Support common set operations\n(b1 \u0026 b2).size # =\u003e 300\n(b1 ^ b2).size # =\u003e 600\n(b2 - b1).size # =\u003e 600\n(b1 - b2).empty? # =\u003e true\nb1 \u003c b2 # =\u003e true\n(b2 - b1) == (b1 ^ b2) # =\u003e true\n\n# (De)Serialization (also available via Marshal#{dump,load})\ndump = bitmap.serialize\nloaded = Roaring::Bitmap64.deserialize(dump)\nloaded == bitmap # =\u003e true\n```\n\n## Development\n\nThis is a Ruby wrapper around [CRoaring](https://github.com/RoaringBitmap/CRoaring)\n\nAfter checking out the repo, run `bin/setup` to install dependencies. Then, run `rake test` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.\n\nTo install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and the created tag, and push the `.gem` file to [rubygems.org](https://rubygems.org).\n\n## Contributing\n\nBug reports and pull requests are welcome on GitHub at https://github.com/jhawthorn/roaring. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [code of conduct](https://github.com/jhawthorn/roaring/blob/main/CODE_OF_CONDUCT.md).\n\n## License\n\nThe gem is available as open source under the terms of the [Apache License, Version 2.0](https://opensource.org/licenses/Apache-2.0).\n\n## Code of Conduct\n\nEveryone interacting in the Roaring project's codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/jhawthorn/roaring/blob/main/CODE_OF_CONDUCT.md).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjhawthorn%2Froaring-ruby","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjhawthorn%2Froaring-ruby","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjhawthorn%2Froaring-ruby/lists"}