blob: 17def9300441444a15e5fb37eb74b1c34a807491 [file] [log] [blame]
MG Mud User88f12472016-06-24 23:31:02 +02001SYNOPSIS
Zesstraecdd9482019-09-23 22:45:14 +02002 mixed * m_entry(mapping map, mixed key)
MG Mud User88f12472016-06-24 23:31:02 +02003
Zesstra715ec202025-07-09 22:18:31 +02004DESCRIPTION
5 Query the mapping <map> for the entry for <key> and return all
6 its values in one array.
MG Mud User88f12472016-06-24 23:31:02 +02007
Zesstra715ec202025-07-09 22:18:31 +02008 If <map> does not contain <key>, 0 is returned.
MG Mud User88f12472016-06-24 23:31:02 +02009
Zesstra715ec202025-07-09 22:18:31 +020010 Note: the efun m_add() can be used to add all values for an entry
11 at once.
12
13EXAMPLES
14 mapping m = ([ 1:"foo";-1, 2:"bar";-2 ]);
15
MG Mud User88f12472016-06-24 23:31:02 +020016 m_entry(m, 0) -> 0
Zesstra715ec202025-07-09 22:18:31 +020017 m_entry(m, 1) -> ({ "foo", -1 })
MG Mud User88f12472016-06-24 23:31:02 +020018
Zesstra715ec202025-07-09 22:18:31 +020019HISTORY
20 Introduced in LDMud 3.2.10.
MG Mud User88f12472016-06-24 23:31:02 +020021
Zesstra715ec202025-07-09 22:18:31 +020022SEE ALSO
MG Mud User88f12472016-06-24 23:31:02 +020023 m_add(E), m_contains(E), mappings(LPC), member(E)