"remove" (mapping::remove)

Removes the key and the associated value.

Synopsis

int mapping.remove(T key);

Parameters

Parameter Description
key Mapping key

Description

Removes the specified key and its associated value from the mapping.

Example

main()
{
  mapping m = makeMapping("city", "Vienna", "country", "Austria");
  m.remove("city");
  DebugN(m.count());          // 1
  DebugN(m.contains("city")); // FALSE
}

Assignment

Mapping