Skip to main content

AbstractLinkedListIterator

AccessAbstractFinalExtendsImplements
YesNoAbstractIteratorILinkedListIterator

UML Diagram​

Parameters

none

Methods​

attachLinkedList​

…

FB_init​

  • Parameters:
    • bInitRetains (BOOL): if TRUE, the retain variables are initialized (warm start / cold start)
    • bInCopyCode (BOOL): if TRUE, the instance afterwards gets moved into the copy code (online change)
    • list (REFERENCE TO LinkedList): list that is used to iterate
  • Return type: BOOL

The constructor FB_init is needed to create an unique hash code.…

hasNext​

  • Return type: BOOL

This method returns if there exists another element to iterate to.…

iterate​

This method returns the next object in the iteration and returns an execution state.…

reset​

  • Return type: VOID

This method resets the iterator.…

Code​

Declaration​

FUNCTION_BLOCK ABSTRACT AbstractLinkedListIterator EXTENDS AbstractIterator IMPLEMENTS ILinkedListIterator
VAR
{attribute 'hide'}
list :REFERENCE TO LinkedList;
currentElement :CNM_CollectionInterfaces.IDoublyLinkedElement;
direction :IterationDirection;
END_VAR