If you don't like dealing with Scripting.dictionary you might want to try out this thing I whipped up yesterday evening and this morning.
Basically just a simple wrapper around Scripting.dictionary to make the API a little bit less stupid. By "stupid" I mean "not like the awesome Python dict API".
Created for the following reasons..
Wanted to get a basic understanding of AutoItObject.
Wanted to get a basic understanding of the Micro unit test framework.
As of 11/4/2014 AutoIt Stable has no native dict or associative array type. A >Map type is in the current AutoIt beta.
It's laborious to use Scripting.dictionary all the time.
The Python dict API is better than Scripting.dictionary's
I thought about writing my own hash table implementation in AutoIt, but on balance I decided it wasn't worth the effort and just stuck to Scripting.dictionary to save time/effort.
As you can see I've got a decent number of unit tests for such a simple implementation, so it should be quite robust.
$dict = _DictCreate()
ConsoleWrite($dict.len()) ; Outputs 0
ConsoleWrite($dict.get("key2")) ; Outputs 'value2'
ConsoleWrite($dict.len()) ; Outputs 3
ConsoleWrite($dict.contains("key2") ; Outputs True
$dict.set("key4", $dict.get("key4") + 1)
ConsoleWrite($dict.get("key4")) ; Outputs 2
ConsoleWrite($dict.contains("key4")) ; Outputs False
$aPairs = $dict.pairs()
_ArrayDisplay($aPairs) ; Displays 2d array with column one contains keys, and column two
; containing associated values
$aKeys = $dict.keys()
_ArrayDisplay($aKeys) ; Displays array containing all keys
$aValues = $dict.values()
_ArrayDisplay($aValues) ; Displays array of all values
$aDesiredKeys = ["key1", "key3"]
$aValues = $dict.values($aDesiredKeys)
_ArrayDisplay($aValues) ; Displays array of values for key1 and key3
GET IT HERE