Insert Into Map Function

Owning Palette: Map VIs and Functions

Requires: Base Development System

Inserts a key and its associated value into a map. If the key is already included in the map, this function replaces the original value of the key with the new associated value.

Example

 Add to the block diagram  Find on the palette
map in specifies the map in which you want to insert a key-value entry. This input accepts a map of any data type. The default data type is a map of 32-bit signed integers.
key specifies the key of the entry to insert into the map.

The key must be of the same data type as the existing keys in the map.
value specifies the value of the entry. This input must be of the same data type as the existing values in the map.
map out returns the map with the inserted entry.
key already included? returns whether map in already includes key. If key already included? is TRUE, this function replaces the associated value of key in map in with value and returns the resulting map in map out.
value unchanged? returns whether any values in the input map are updated after the insertion.

Example

Refer to the Map Collection - Comparing Test Results VI in the labview\examples\Collections directory for an example of using the Insert Into Map function.

 Open example  Find related examples