I have registered a gotoFileContributor extension implementing ChooseByNameContributor.
My first implementation of getItemsByName() was returning a custom implementation of NavigationItem that implemented both getPresentation() and navigate().
Unfortunately I got a ClassCastException because I discovered later that the GotoFileAction assumes that these NavigationItems are in fact PsiFiles.
The presentation aspect is not as demanding (no CCE) but it discardes totally the provided ItemPresentation. Apparently it just does a toString() to present it in the list if it isn't a PsiFile.
So my question is: is it a debt item not yet removed? Is it reasonable to expect that in a not too distant future the GotoFileAction should just call navigate() on the returned NavigationItem and that the ItemPresentation will be used to render each candidate?