void (Project project, PsiElement[] adjustedElements, PsiElement initialTargetElement, MoveCallback moveCallback) { if (!CommonRefactoringUtil.checkReadOnlyStatusRecursively(project, Arrays.asList(adjustedElements), true)) { return; } String initialTargetPackageName = getInitialTargetPackageName(initialTargetElement, adjustedElements); PsiDirectory initialTargetDirectory = getInitialTargetDirectory(initialTargetElement, adjustedElements); boolean searchTextOccurrences = Stream.of(adjustedElements).anyMatch(TextOccurrencesUtil::isSearchTextOccurrencesEnabled); boolean searchInComments = JavaRefactoringSettings.getInstance().MOVE_SEARCH_IN_COMMENTS; boolean searchForTextOccurrences = JavaRefactoringSettings.getInstance().MOVE_SEARCH_FOR_TEXT; new MoveClassesOrPackagesDialog( project, searchTextOccurrences, adjustedElements, initialTargetElement, moveCallback, initialTargetPackageName, initialTargetDirectory, searchInComments, searchForTextOccurrences ).show(); }