1// Copyright (C) 2018 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3#ifndef HASHMAP_H
4#define HASHMAP_H
5
6#include <QtCore/qhash.h>
7
8namespace WTF {
9
10template<typename Key, typename Value>
11class HashMap final : public QHash<Key, Value>
12{
13public:
14 void add(const Key &k, const Value &v) { QHash<Key, Value>::insert(k, v); }
15 Value get(const Key &k) { return QHash<Key, Value>::value(k); }
16};
17
18}
19
20using WTF::HashMap;
21
22#endif
23

Provided by KDAB

Privacy Policy
Learn Advanced QML with KDAB
Find out more

source code of qtdeclarative/src/3rdparty/masm/stubs/wtf/HashMap.h