Using the Get method, you get the number of occurrences for the character at position i. In the following example, the variable counter represents the Dictionary data type to store a value representing the number of occurrences for each character in the customerName. In AL you use the Dictionary Data Type instead. Previously in C/AL, one would have typically used an in-memory temporary table to create a key-value data structure, as shown in the code below. The Dictionary data type does not support holding instantiated records. A key cannot be null, but a value can be, only when the value type is a reference type. Every key in a Dictionary must be unique. Gets a collection containing the values in the Dictionary.Įach addition to the dictionary consists of a value, and its associated key. Sets the value associated with the specified key. Removes the value with the specified key from the Dictionary. Gets a collection containing the keys in the Dictionary. Gets the value associated with the specified key. Gets the number of key/value pairs contained in the Dictionary. Method nameĪdds the specified key and value to the dictionary.ĭetermines whether the Dictionary contains the specified key. The following methods are available on instances of the Dictionary data type. The Dictionary data type is optimized for fast lookup of values. Represents an unordered collection of keys and values. Version: Available or changed with runtime version 1.0.
0 Comments
Leave a Reply. |