Class: DictIterator

PDFNet. DictIterator


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()
  }

Extends

Methods


destroy()

Destructor
Inherited From:
Returns:
Type
Promise.<void>

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
Promise.<boolean>

key()

Returns:
A promise that resolves to the key of the current dictionary entry.
Type
Promise.<PDFNet.Obj>

next()

Advances the iterator to the next element of the collection.
Returns:
Type
Promise.<void>

takeOwnership()

Take the ownership of this object, so that PDFNet.runWithCleanup won't destroy this object.
Inherited From:
Returns:
Type
void

value()

Returns:
A promise that resolves to the value of the current dictionary entry.
Type
Promise.<PDFNet.Obj>