component/src/main/java/org/wso2/extension/siddhi/execution/extrema/util/DoublyLinkedList.java
public void addAfterLast(ListNode<T> node) {
        node.setPreviousNode(tail);
        node.setNextNode(null);
        if (size == 0) {
            head = node;
        } else {
            tail.setNextNode(node);
        }
        tail = node;
        size++;
    }
/**
     * Add a node after the last node in the list
     *
     * @param node The node to be added as the last node of the list
     */
Add a node after the last node in the list
@param node The node to be added as the last node of the list
Add a node after the last node in the list @param node The node to be added as the last node of the list
public void addAfterLast(ListNode<T> node) {
        node.setPreviousNode(tail);
        node.setNextNode(null);
        if (size == 0) {
            head = node;
        } else {
            tail.setNextNode(node);
        }
        tail = node;
        size++;
    }
public void addAfterLast ( ListNode < T > node ) { node . setPreviousNode ( tail ) ; node . setNextNode ( null ) ; if ( size == 0 ) { head = node ; } else { tail . setNextNode ( node ) ; } tail = node ; size ++ ; }
Add a node after the last node in the list
 @param node The node to be added as the last node of the list
Add a node after the last node in the list @param node The node to be added as the last node of the list