public T grow ( ) { if ( size >= data . length ) { T a = createInstance ( ) ; add ( a ) ; return a ; } else { T a = data [ ( start + size ) % data . length ] ; if ( a == null ) { data [ ( start + size ) % data . length ] = a = createInstance ( ) ; } size ++ ; return a ; } }
Adds a new element to the end of the list and returns it . If the inner array isn t large enough then it will grow .