Migration 2.x to 5.x ElastiSearch InnerHit

During Migration of elasticsearch 2.x to 5.x I was getting some compilation issue over InnerHit

InnerHit innerHit;

innerHit.setFetchSource(includes.toArray(new String[includes.size()]),
                        excludes.toArray(new String[excludes.size()]))

What could be the equivalent code with which I can refactor or compile code ?

https://discuss.elastic.co/t/elasticsearch-java-api-5-4-how-to-get-the-inner-hits-of-a-nested-query/90582?u=mazreena_begum