Skip to content

Commit

Permalink
Merge pull request #37 from rinde/update-readme
Browse files Browse the repository at this point in the history
move multimap overview to its own file and extend it
  • Loading branch information
rinde authored Dec 15, 2023
2 parents 6505c41 + 42f066d commit 8c8fa2f
Show file tree
Hide file tree
Showing 2 changed files with 187 additions and 97 deletions.
99 changes: 2 additions & 97 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@ Built on top of the excellent [smallvec](https://github.com/servo/rust-smallvec)
| ⬜️⬜️⬜️⬜️⬜️ | EnumVecMultimap | `EnumMap<K, Vec<V>> ` |
| ⬜️⬜️⬜️⬜️⬜️ | EnumEnumMultimap | `EnumMap<K, EnumSet<V>>` |

[A detailed overview](doc/multimap.md).

## Multisets

| Completion | Name | Behaves as |
Expand All @@ -46,100 +48,3 @@ Built on top of the excellent [smallvec](https://github.com/servo/rust-smallvec)
| ⬜️⬜️⬜️⬜️⬜️ | EnumMultiset | `EnumMap<K,usize>` |

Some work is already done [in this PR](https://github.com/rinde/more_collections/pull/8).

## Multimaps overview

| Method | HashSetMultimap | HashVecMultimap | IndexSetMultimap | IndexVecMultimap |
| ------------------------------------- | --------------- | --------------- | ---------------- | ---------------- |
| new() |||||
| with_key_capacity() |||||
| with_hasher() |||||
| with_key_capacity_and_hasher() |||||
| key_capacity() |||||
| keys() |||||
| values() |||||
| values_mut() | maybe | maybe | maybe | maybe |
| iter() |||||
| len() |||||
| is_empty() |||||
| keys_len() |||||
| reserve() |||||
| shrink_keys_to_fit() |||||
| shrink_values_to_fit() |||||
| shrink_keys_to() | planned | planned | - | - |
| shrink_values_to() | planned | planned | - | planned |
| entry() | planned | planned | planned | planned |
| get() |||||
| get_key_values() |||||
| contains_key() |||||
| get_mut() | maybe | maybe | maybe | maybe |
| insert() |||||
| remove_key() |||||
| remove_key_entry() |||||
| retain() |||||
| into_keys() |||||
| into_values() |||||
| remove() |||||
| contains() |||||
| as_map() |||||
| into_map() |||||
| __IndexMap keys methods__ |
| insert_full() | - | - |||
| get_full() | - | - |||
| get_key_index() | - | - |||
| get_full_mut() | - | - | maybe | maybe |
| swap_remove() | - | - | planned | planned |
| swap_remove_entry() | - | - | planned | planned |
| swap_remove_full() | - | - | planned | planned |
| shift_remove() | - | - | planned | planned |
| shift_remove_entry() | - | - | planned | planned |
| shift_remove_full() | - | - | planned | planned |
| pop() | - | - | planned | planned |
| sort_keys() | - | - | planned | planned |
| sort_by() | - | - | planned | planned |
| sorted_by() | - | - | planned | planned |
| reverse() | - | - | planned | planned |
| get_index() | - | - | planned | planned |
| get_index_mut() | - | - | maybe | maybe |
| first() | - | - | planned | planned |
| first_mut() | - | - | maybe | maybe |
| last() | - | - | planned | planned |
| last_mut() | - | - | maybe | maybe |
| swap_remove_index() | - | - | planned | planned |
| shift_remove_index() | - | - | planned | planned |
| swap_indices() | - | - | planned | planned |
| __Set values methods__ |
| difference() | planned | - | planned | - |
| symmetric_difference() | planned | - | planned | - |
| intersection() | planned | - | planned | - |
| union() | planned | - | planned | - |
| is_disjoint() | planned | - | planned | - |
| is_subset() | planned | - | planned | - |
| is_superset() | planned | - | planned | - |
| __Consistent ordered values methods__ |
| sort_values() | - | planned | planned | planned |
| sort_values_by() | - | planned | planned | planned |
| TODO consider adding more mutators |
| __Traits__ |
| Extend |||||
| FromIterator |||||
| From wrapped type |||||
| IntoIterator |||||
| Default |||||
| Index |||||
| Eq |||||
| PartialEq |||||
| Debug |||||
| Clone |||||
| Serializable | planned | planned | planned | planned |
| Deserializable | planned | planned | planned | planned |


# Todo

- [ ] Add benches
- [ ] Look into `no_std` compatibility
- [ ] Look into `WASM` compatibility
- [ ] Look into no-unsafe clippy rule
- [ ] Add features to disable parts of the crate (e.g. dependencies should be optional)
- [ ] Implement custom iterators following this advice: https://stackoverflow.com/questions/52079983/what-is-the-advantage-of-publishing-a-concrete-type-in-a-crates-api-instead-of
Loading

0 comments on commit 8c8fa2f

Please sign in to comment.