new DictIterator()
DictIterator is used to traverse key/value pairs in a dictionary. For example a DictIterator can be used to print out all the entries in a given Obj dictionary as follows:
DictIterator itr = dict.GetDictIterator(); while (itr.HasNext()) { Obj key = itr.Key(); cout << key.GetName() << endl; Obj value = itr.Value(); // ... itr.Next() }
Methods
-
assign()
-
Copy Constructor
Returns:
A promise that resolves to an object of type: "DictIterator"
- Type
- PDFNet.DictIterator
-
destroy()
-
Destructor
-
hasNext()
-
Returns:
A promise that resolves to true if the iterator can be successfully advanced to the next element; false if the end collection is reached.
- Type
- boolean
-
key()
-
Returns:
A promise that resolves to the key of the current dictionary entry.
- Type
- PDFNet.Obj
-
next()
-
Advances the iterator to the next element of the collection.
-
value()
-
Returns:
A promise that resolves to the value of the current dictionary entry.
- Type
- PDFNet.Obj