Skip to content

IMap<TKey,TValue>

IMap<TKey, TValue>

IMap<TKey, TValue> is an interface for implementing generic collections of key/value pairs.

Description

The IMap<TKey, TValue> interface defines basic methods to work with collections whose data are stored as key/value pairs.

Declaration

template<typename TKey, typename TValue>
   interface IMap : public ICollection<TKey>

Header

#include <Generic\Interfaces\IMap.mqh>

Inheritance Hierarchy

ICollection

IMap

Direct descendants

: CHashMap, CSortedMap

Class Methods

MethodDescription
AddAdds a key/value pair to a collection
ContainsDetermines whether a collection contains the key/value table with the specified key
RemoveRemoves the first occurrence of a key/value pair from a collection
TryGetValueGets an element with the specified key from a collection
TrySetValueChanges the value of the key/value pair from a collection at the specified key
CopyToCopies all key/value pairs from a collection to specified arrays, starting at the specified index
Last updated on