patricia_router
Radix Tree implementation for Rust.
Installation
Add this to your application's Cargo.toml
.
Usage
let mut router = new;
router.add;
router.add;
router.add;
router.add;
router.add;
router.add;
let mut result = router.find;
assert_eq!;
assert_eq!;
// named parameters match a single path segment
result = router.find;
assert_eq!;
assert_eq!;
// catch all parameters match everything
result = router.find;
assert_eq!;
assert_eq!;
Development
Run tests following commands.
Code submitted to this repository should be formatted according to cargo +nightly fmt
.
Implementation
This project has been inspired and adapted from luislavena/radix Crystal implementation, respectively.