]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
common: str_map: add helper methods to get values from maps
authorJoao Eduardo Luis <joao.luis@inktank.com>
Mon, 28 Jul 2014 22:09:24 +0000 (23:09 +0100)
committerJoao Eduardo Luis <joao.luis@inktank.com>
Wed, 27 Aug 2014 17:21:47 +0000 (18:21 +0100)
commitb1af4bd0a1adca1de5e39034f11b0c7138f138e5
treea5986564f484385cdd66778f07ba550ba8042179
parent15e9fc45bee10fae1657a7449e72c6ee41e9daac
common: str_map: add helper methods to get values from maps

Both methods obtain values for keys from a given map.  Main distinction
is that one method will return a default value if key is not present and
if the default value is specified (i.e., not NULL), while the other
method will return the value of a fallback key if the key is not
present.

Signed-off-by: Joao Eduardo Luis <joao.luis@inktank.com>
src/common/str_map.cc
src/include/str_map.h