F_VN_AdvanceIterator
Advance an iterator by the specified offset.
Syntax
Definition:
FUNCTION F_VN_AdvanceIterator : HRESULT
VAR_INPUT
ipIterator : ITcVnForwardIterator;
nOffset : LINT;
hrPrev : HRESULT;
END_VAR
Inputs
|
Name |
Type |
Description |
|---|---|---|
|
ipIterator |
Iterator to be advanced | |
|
nOffset |
LINT |
Offset, by which ipIterator is advanced |
|
hrPrev |
HRESULT indicating the result of previous operations (If SUCCEEDED(hrPrev) equals false, no operation is executed.) |
Further information
The function F_VN_AdvanceIterator increments or decrements an iterator by a certain offset nOffset.
If the offset nOffset is always to be 1, the simpler function F_VN_IncrementIterator can also be used.
Parameter
Iterator
The parameter ipIterator is of the type ITcVnForwardIterator. Since ITcVnBidirectionalIterator and ITcVnRandomAccessIterator inherit from it, these can also be transferred to the function. If a forward iterator is to be decremented, an internal attempt is made to transform it into a bidirectional iterator and to decrement it.
Offset
The offset nOffset defines by how much the iterator ipIterator is to be incremented or decremented. If nOffset > 0 it is incremented; if nOffset < 0 it is decremented.
Related functions
Required License
TC3 Vision Base
Return value