question: private void writeObject ( ObjectOutputStream oos ) throws IOException { oos . defaultWriteObject ( ) ; oos . writeInt ( index . size ( ) ) ; for ( int i = 0 , sz = index . size ( ) ; i < sz ; ++ i ) { oos . writeUTF ( index . get ( i ) ) ; } }
target:  Custom serializer. This is possible since the Index is guaranteed to assign contiguous values.