public ListBuffer < A > append ( A x ) { Assert . checkNonNull ( x ) ; if ( shared ) copy ( ) ; List < A > newLast = List . of ( x ) ; if ( last != null ) { last . tail = newLast ; last = newLast ; } else { elems = last = newLast ; } count ++ ; return this ; }
Append an element to buffer .