question: public List < Entry < E > > asList ( ) { if ( nonNullList == null ) { if ( array == null || array . length ( ) == 0 ) { nonNullList = Collections . emptyList ( ) ; } else { List < Entry < E > > list = new ArrayList < > ( array . length ( ) ) ; for ( int i = 0 ; i < array . length ( ) ; i ++ ) { E e = array . get ( i ) ; if ( e != null ) { list . add ( new Entry < > ( i , e ) ) ; } } nonNullList = list ; } } return nonNullList ; }
target:  Returns the it as a non null list, with an Entry wrapping each value allowing to retain its index.