collections-more

Crates.iocollections-more
lib.rscollections-more
version0.1.4
sourcesrc
created_at2017-12-06 11:46:13.724998
updated_at2017-12-17 23:24:56.549502
descriptionCommon data structure and algorithms for rust-lang to complete the already excellent std::collections
homepagehttps://www.github.com/mfournial/collections-rust
repositoryhttps://www.github.com/mfournial/collections-rust
max_upload_size
id41918
size24,684
Mike Fournial (mfournial)

documentation

https://gitlab.doc.ic.ac.uk/mmf115/collections-rust/-/jobs/artifacts/master/download?job=doc

README

Collections and algorithms for Rust-lang

Crates version Documentation Build Status Pipeline Status codecov standard-readme compliant

This crate is an extension of the rust collections crate. If you're used to C++ algorithms and the various Java collections you'll feel just at home.
You should use this crate if you want to use some general purpose data structures very easily. Each of them have been tested, and the concurrent versions are thread safe. So scale your project and use lighting fast DS with this crate!

Celebs talking about this project:

The best open source project yet (Linus Torvalds)
I wish I had this idea for Microsoft (Bill Gates)
Collections-more is a true revolution (Steve Jobs at RustConf 2017)

Table of contents

Install

Add this line to your cargo.toml in your [dependencies] section:

[dependencies]
# ...
collections_more = "X.X.X"

replacing X.X.X with the version number with the one on the badge above and you should be good to go!

Usage

Usage is still being decided and shall for now be marked as a work in progress. We have to evaluate what's the Rust way of packaging easily before committing ourselves to a design.
As for example of how to use the different data structures, please refer to the integration tests in the tests folder that show exactly how everything will be holding on in time. The documentation should be very useful to guide you on how to use the various functionalities of this project.
The full details of what is currently available in this library can be found in the documentation, this document being only a facade to the project. Nevertheless it is important to give a few example to understand the purpose of this library so here they are:

extern crate collections_more;

// snip

use collections_more::priority_queue::PriorityQueue;

fn main() {
	let pq = PriorityQueue::pqueue!(1, 5, 3); // Creates a priority_queue using the macro
	asserteq!(Some(5), pq.poll()); // Gets the biggest element of the queue O(1)
	asserteq!(2, pq.len()); // Size of the queue after removing biggest element
}

Contribute

We most welcome contributions from you. Issue is generally a good safe way to go. For more active participation, forking the project and opening a pull request is also acceptable. For security related issues, a more direct email is recommended (email in cargo.toml file).
You may take a look at the code of conduct that apply as some sort of by-law between participants. If you have anything to report please send an email at the address in the cargo.toml file.

License

MIT © 2017 - mfournial Mayeul (Mike) Fournial

Commit count: 0

cargo fmt