FilePath (@Nullable Object userObject) { if (userObject instanceof Change change) { return ChangesUtil.getFilePath(change); } else if (userObject instanceof VirtualFile file) { return VcsUtil.getFilePath(file); } else if (userObject instanceof FilePath filePath) { return filePath; } return null; }