- Notifications
You must be signed in to change notification settings - Fork3
Elixir implementation of bidirectional map and multimap
License
NotificationsYou must be signed in to change notification settings
mkaput/elixir-bimap
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
Elixir implementation of bidirectional map (BiMap
) and multimap (BiMultiMap
).
The package can be installed by addingbimap
to your list of dependencies inmix.exs
:
defdepsdo[{:bimap,"~> 1.3"}]end
For more examples, checkoutBiMap
andBiMultiMap
on hex docs.
iex(1)>Mix.install[:bimap]iex(2)>bm=BiMap.new(a:1,b:2)BiMap.new([a:1,b:2])iex(3)>BiMap.get(bm,:a)1iex(4)>BiMap.get_key(bm,2):biex(5)>BiMap.put(bm,:a,3)BiMap.new([a:3,b:2])iex(6)>BiMap.put(bm,:c,2)BiMap.new([a:1,c:2])
iex(1)>Mix.install[:bimap]iex(2)>mm=BiMultiMap.new(a:1,b:2,b:1)BiMultiMap.new([a:1,b:1,b:2])iex(3)>BiMultiMap.get(mm,:a)[1]iex(4)>BiMultiMap.get_keys(mm,1)[:a,:b]iex(5)>BiMultiMap.put(mm,:a,3)BiMultiMap.new([a:1,a:3,b:1,b:2])
All notable changes to this project are documented on theGitHub releases page.
See theLICENSE file for license rights and limitations (MIT).
About
Elixir implementation of bidirectional map and multimap
Topics
Resources
License
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Uh oh!
There was an error while loading.Please reload this page.
Contributors6
Uh oh!
There was an error while loading.Please reload this page.