mount method

  1. @protected
  2. @mustCallSuper
void mount(
  1. ElLinkedList<N> list,
  2. N? prev,
  3. N? next
)

当节点被关联时调用

Implementation

@protected
@mustCallSuper
void mount(ElLinkedList<N> list, N? prev, N? next) {
  assert(
    _list == null,
    'ElLinkedNode Error: 节点已经挂载,不可重复关联链表!\n'
    '$this',
  );
  _prev = prev;
  _next = next;
  _list = list;
  list._length++;
}