github.com/djordje200179/extendedlibrary/datastructures@v1.7.1-0.20240227175559-d09520a92dd4/cols/synclist/node.go (about)

     1  package synclist
     2  
     3  // Node is a node in a singly linked list.
     4  type Node[T any] struct {
     5  	Value T // The value stored in the node.
     6  
     7  	next *Node[T]
     8  }
     9  
    10  // Next returns the next node in the list.
    11  func (node Node[T]) Next() *Node[T] {
    12  	return node.next
    13  }