Unnamed: 0 int64 0 305k | body stringlengths 7 52.9k | name stringlengths 1 185 |
|---|---|---|
30,800 | boolean (@NotNull PsiClass element) { callback.accept(element); return false; } | execute |
30,801 | void (final boolean generateFinal, GrVariable variable) { perform(generateFinal, PsiModifier.FINAL, variable); } | perform |
30,802 | void (final boolean generateFinal, final String modifier, final GrVariable variable) { final Document document = myEditor.getDocument(); LOG.assertTrue(variable != null); final GrModifierList modifierList = variable.getModifierList(); LOG.assertTrue(modifierList != null); final int textOffset = modifierList.getTextOffs... | perform |
30,803 | GrExpression (GrVariable variable, GrExpression initializer) { PsiType ltype = findLValueType(initializer); PsiType rtype = initializer.getType(); GrExpression rawExpr = (GrExpression)PsiUtil.skipParentheses(initializer, false); if (ltype == null || TypesUtil.isAssignableWithoutConversions(ltype, rtype) || !TypesUtil.i... | insertExplicitCastIfNeeded |
30,804 | PsiType (GrExpression initializer) { if (initializer.getParent() instanceof GrAssignmentExpression && ((GrAssignmentExpression)initializer.getParent()).getRValue() == initializer) { return ((GrAssignmentExpression)initializer.getParent()).getLValue().getNominalType(); } else if (initializer.getParent() instanceof GrVar... | findLValueType |
30,805 | GrStatement (PsiElement @NotNull [] occurrences, @NotNull PsiElement scope) { PsiElement parent = PsiTreeUtil.findCommonParent(occurrences); PsiElement container = getEnclosingContainer(parent); assert container != null; PsiElement anchor = findAnchor(occurrences, container); assertStatement(anchor, scope); return (GrS... | getAnchor |
30,806 | PsiElement (PsiElement place) { PsiElement parent = place; while (true) { if (parent == null) { return null; } if (parent instanceof GrDeclarationHolder && !(parent instanceof GrClosableBlock && parent.getParent() instanceof GrStringInjection)) { return parent; } if (parent instanceof GrLoopStatement) { return parent; ... | getEnclosingContainer |
30,807 | List<GrExpression> (final PsiFile file, final Editor editor, final int offset, boolean acceptVoidCalls) { int correctedOffset = correctOffset(editor, offset); final PsiElement elementAtCaret = file.findElementAt(correctedOffset); return collectExpressions(elementAtCaret, acceptVoidCalls); } | collectExpressions |
30,808 | List<GrExpression> (PsiElement elementAtCaret, boolean acceptVoidCalls) { final List<GrExpression> expressions = new ArrayList<>(); for (GrExpression expression = PsiTreeUtil.getParentOfType(elementAtCaret, GrExpression.class); expression != null; expression = PsiTreeUtil.getParentOfType(expression, GrExpression.class)... | collectExpressions |
30,809 | boolean (@Nullable GrExpression expression, boolean acceptVoidCalls) { if (expression instanceof GrParenthesizedExpression) return true; if (PsiUtil.isSuperReference(expression)) return true; if (expression instanceof GrReferenceExpression && expression.getParent() instanceof GrCall) { final GroovyResolveResult resolve... | expressionIsIncorrect |
30,810 | int (Editor editor, int offset) { Document document = editor.getDocument(); CharSequence text = document.getCharsSequence(); int correctedOffset = offset; int textLength = document.getTextLength(); if (offset >= textLength) { correctedOffset = textLength - 1; } else if (!Character.isJavaIdentifierPart(text.charAt(offse... | correctOffset |
30,811 | GrVariable (final PsiFile file, final Editor editor, final int offset) { final int correctOffset = correctOffset(editor, offset); final PsiElement elementAtCaret = file.findElementAt(correctOffset); final GrVariable variable = PsiTreeUtil.getParentOfType(elementAtCaret, GrVariable.class); if (variable != null && variab... | findVariableAtCaret |
30,812 | void (@NotNull final Project project, final Editor editor, final PsiFile file, @Nullable final DataContext dataContext) { final SelectionModel selectionModel = editor.getSelectionModel(); if (!selectionModel.hasSelection()) { final int offset = editor.getCaretModel().getOffset(); final List<GrExpression> expressions = ... | invoke |
30,813 | void (final GrExpression selectedValue) { invoke(project, editor, file, selectedValue.getTextRange().getStartOffset(), selectedValue.getTextRange().getEndOffset()); } | pass |
30,814 | void (Editor editor, PsiFile file, SelectionModel selectionModel, int offset) { final GrVariable variable = findVariableAtCaret(file, editor, offset); if (variable == null || variable instanceof GrField || variable instanceof GrParameter) { selectionModel.selectLineAtCaret(); } else { final TextRange textRange = variab... | updateSelectionForVariable |
30,815 | void (@NotNull Project project, PsiElement @NotNull [] elements, DataContext dataContext) { // Does nothing } | invoke |
30,816 | void (@NotNull final Project project, @NotNull final Editor editor, @Nullable final GrExpression expression, @Nullable final GrVariable variable, @Nullable final StringPartInfo stringPart) { final Scope[] scopes = findPossibleScopes(expression, variable, stringPart, editor); Consumer<? super Scope> callback = scope-> {... | getContextAndInvoke |
30,817 | void (final Ref<GrIntroduceContext> ref) { CommandProcessor.getInstance().executeCommand(ref.get().getProject(), () -> ApplicationManager.getApplication().runWriteAction(() -> { GrIntroduceContext context = ref.get(); StringPartInfo stringPart = context.getStringPart(); assert stringPart != null; GrExpression expressio... | extractStringPart |
30,818 | void (@NotNull final GrStatement anchor, @NotNull final Ref<GrIntroduceContext> contextRef) { CommandProcessor.getInstance().executeCommand(contextRef.get().getProject(), () -> ApplicationManager.getApplication().runWriteAction(() -> { GrIntroduceContext context = contextRef.get(); SmartPointerManager pointManager = Sm... | addBraces |
30,819 | GrStatement (@NotNull final GrIntroduceContext context, final boolean replaceAll) { return ReadAction.compute(() -> { PsiElement[] occurrences = replaceAll ? context.getOccurrences() : new GrExpression[]{context.getExpression()}; return getAnchor(occurrences, context.getScope()); }); } | findAnchor |
30,820 | GrIntroduceContext (@NotNull Project project, @NotNull Editor editor, @Nullable GrExpression expression, @Nullable GrVariable variable, @Nullable StringPartInfo stringPart, @NotNull PsiElement scope) { if (variable != null) { final PsiElement[] occurrences = collectVariableUsages(variable, scope); return new GrIntroduc... | getContext |
30,821 | PsiElement[] (GrVariable variable, PsiElement scope) { final List<PsiElement> list = Collections.synchronizedList(new ArrayList<>()); if (scope instanceof GroovyScriptClass) { scope = scope.getContainingFile(); } ReferencesSearch.search(variable, new LocalSearchScope(scope)).forEach(psiReference -> { final PsiElement e... | collectVariableUsages |
30,822 | boolean (final Project project, final GrIntroduceContext context, final Editor editor) { try { if (!CommonRefactoringUtil.checkReadOnlyStatus(project, context.getOccurrences())) { return false; } checkOccurrences(context.getOccurrences()); if (isInplace(context.getEditor(), context.getPlace())) { Map<OccurrencesChooser... | invokeImpl |
30,823 | boolean (@NotNull Editor editor, @NotNull PsiElement place) { final RefactoringSupportProvider supportProvider = LanguageRefactoringSupport.INSTANCE.forContext(place); return supportProvider != null && (editor.getUserData(InplaceRefactoring.INTRODUCE_RESTART) == null || !editor.getUserData(InplaceRefactoring.INTRODUCE_... | isInplace |
30,824 | GrVariable (@NotNull PsiFile file, int startOffset, int endOffset) { GrVariable var = PsiImplUtil.findElementInRange(file, startOffset, endOffset, GrVariable.class); if (var == null) { final GrVariableDeclaration variableDeclaration = PsiImplUtil.findElementInRange(file, startOffset, endOffset, GrVariableDeclaration.cl... | findVariable |
30,825 | GrVariable (@NotNull GrStatement statement) { if (!(statement instanceof GrVariableDeclaration variableDeclaration)) return null; final GrVariable[] variables = variableDeclaration.getVariables(); GrVariable var = null; if (variables.length == 1) { var = variables[0]; } if (var instanceof GrParameter || var instanceof ... | findVariable |
30,826 | GrExpression (PsiFile file, int startOffset, int endOffset) { GrExpression selectedExpr = PsiImplUtil.findElementInRange(file, startOffset, endOffset, GrExpression.class); return findExpression(selectedExpr); } | findExpression |
30,827 | GrExpression (GrStatement selectedExpr) { if (!(selectedExpr instanceof GrExpression selected)) return null; while (selected instanceof GrParenthesizedExpression) selected = ((GrParenthesizedExpression)selected).getOperand(); return selected; } | findExpression |
30,828 | Settings (@NotNull GrIntroduceContext context) { // Add occurrences highlighting ArrayList<RangeHighlighter> highlighters = new ArrayList<>(); HighlightManager highlightManager = null; if (context.getEditor() != null) { highlightManager = HighlightManager.getInstance(context.getProject()); if (context.getOccurrences().... | showDialog |
30,829 | PsiElement (PsiElement @NotNull [] occurrences, @NotNull PsiElement container) { if (occurrences.length == 0) return null; PsiElement candidate; if (occurrences.length == 1) { candidate = findContainingStatement(occurrences[0]); } else { candidate = occurrences[0]; while (candidate != null && candidate.getParent() != c... | findAnchor |
30,830 | void (@Nullable PsiElement anchor, @NotNull PsiElement scope) { if (!(anchor instanceof GrStatement)) { LOG.error("cannot find anchor for variable", new Throwable(), AttachmentFactory.createContext(scope.getText())); } } | assertStatement |
30,831 | PsiElement (@Nullable PsiElement candidate) { while (candidate != null && (candidate.getParent() instanceof GrLabeledStatement || !(PsiUtil.isExpressionStatement(candidate)))) { candidate = candidate.getParent(); } return candidate; } | findContainingStatement |
30,832 | void (GrVariable var) { final PsiElement parent = var.getParent(); if (((GrVariableDeclaration)parent).getVariables().length == 1) { parent.delete(); } else { GrExpression initializer = var.getInitializerGroovy(); if (initializer != null) initializer.delete(); //don't special check for tuple, but this line is for the t... | deleteLocalVar |
30,833 | GrVariable (@NotNull GrIntroduceContext context) { final GrVariable var = context.getVar(); if (var != null) { return var; } return resolveLocalVar(context.getExpression()); } | resolveLocalVar |
30,834 | GrVariable (@Nullable GrExpression expression) { if (expression instanceof GrReferenceExpression ref) { final PsiElement resolved = ref.resolve(); if (PsiUtil.isLocalVariable(resolved)) { return (GrVariable)resolved; } return null; } return null; } | resolveLocalVar |
30,835 | boolean (final PsiElement @NotNull [] occurrences) { for (PsiElement element : occurrences) { if (element instanceof GrReferenceExpression) { if (PsiUtil.isLValue((GroovyPsiElement)element)) return true; if (ControlFlowUtils.isIncOrDecOperand((GrReferenceExpression)element)) return true; } } return false; } | hasLhs |
30,836 | PsiElement (@Nullable GrExpression expr, @Nullable GrVariable var, @Nullable StringPartInfo stringPartInfo) { if (var != null) return var; if (expr != null) return expr; if (stringPartInfo != null) return stringPartInfo.getLiteral(); throw new IncorrectOperationException(); } | getCurrentPlace |
30,837 | boolean (GrIntroduceDialog dialog) { final GrIntroduceSettings settings = dialog.getSettings(); if (settings == null) return false; String varName = settings.getName(); boolean allOccurrences = settings.replaceAllOccurrences(); final MultiMap<PsiElement, String> conflicts = isOKImpl(varName, allOccurrences); return con... | isOK |
30,838 | boolean (final MultiMap<PsiElement, String> conflicts, final Project project) { ConflictsDialog conflictsDialog = new ConflictsDialog(project, conflicts); return conflictsDialog.showAndGet(); } | reportConflicts |
30,839 | PsiElement (boolean replaceAllOccurrences) { if (replaceAllOccurrences) { if (myContext.getOccurrences().length > 0) { GroovyRefactoringUtil.sortOccurrences(myContext.getOccurrences()); return myContext.getOccurrences()[0]; } else { return myContext.getPlace(); } } else { final GrExpression expression = myContext.getEx... | getFirstOccurrence |
30,840 | String (String varName, boolean allOccurences) { MultiMap<PsiElement, String> list = isOKImpl(varName, allOccurences); String result = ""; final String[] strings = ArrayUtilRt.toStringArray(list.values()); Arrays.sort(strings); for (String s : strings) { result = result + s.replaceAll("<b><code>", "").replaceAll("</cod... | isOKTest |
30,841 | void (@NotNull PsiElement startElement, @NotNull MultiMap<PsiElement, String> conflicts, @NotNull String varName, double startOffset) { PsiElement child = startElement.getFirstChild(); while (child != null) { // Do not check defined classes, methods, closures and blocks before if (child instanceof GrTypeDefinition || c... | validateOccurrencesDown |
30,842 | void (PsiElement startElement, MultiMap<PsiElement, String> conflicts, @NotNull String varName, double startOffset) { PsiElement prevSibling = startElement.getPrevSibling(); while (prevSibling != null) { if (!(GroovyRefactoringUtil.isAppropriateContainerForIntroduceVariable(prevSibling) && prevSibling.getTextRange().ge... | validateVariableOccurrencesUp |
30,843 | String (String name, boolean increaseNumber) { String result = name; if (!isOKImpl(name, true).isEmpty() && !increaseNumber || name.isEmpty()) { return ""; } int i = 1; while (!isOKImpl(result, true).isEmpty()) { result = name + i; i++; } return result; } | validateName |
30,844 | Project () { return myContext.getProject(); } | getProject |
30,845 | String () { throw new UnsupportedOperationException(); } | getName |
30,846 | PsiElement () { return myToSearchFor; } | getToSearchFor |
30,847 | GrParameterListOwner () { return myOwner; } | getToReplaceIn |
30,848 | GrExpression (GrExpression initializer) { if (myField == null) return initializer; final GrReferenceExpression[] replacedRef = {null}; initializer.accept(new GroovyRecursiveElementVisitor() { @Override public void visitReferenceExpression(@NotNull GrReferenceExpression expression) { final GrExpression qualifierExpressi... | fixInitializer |
30,849 | void (@NotNull GrReferenceExpression expression) { final GrExpression qualifierExpression = expression.getQualifier(); if (qualifierExpression != null) { qualifierExpression.accept(this); } else { final PsiElement result = expression.resolve(); if (expression.getManager().areElementsEquivalent(result, myField)) { try {... | visitReferenceExpression |
30,850 | String () { return myExpression.getText(); } | getText |
30,851 | PsiType () { return myExpression.getType(); } | getType |
30,852 | GrExpression () { if (myExpression.isValid()) { return myExpression; } else if (myMarker != null && myMarker.isValid()) { PsiElement at = myFile.findElementAt(myMarker.getStartOffset()); if (at != null) { return GroovyPsiElementFactory.getInstance(myFile.getProject()).createExpressionFromText(myExpression.getText(), at... | getExpression |
30,853 | void () { super.init(); JavaRefactoringSettings settings = JavaRefactoringSettings.getInstance(); initReplaceFieldsWithGetters(settings); myDeclareFinalCheckBox.setSelected(hasFinalModifier()); myDelegateViaOverloadingMethodCheckBox.setVisible(myInfo.getToSearchFor() != null); setTitle(RefactoringBundle.message("introd... | init |
30,854 | void (ItemEvent e) { mySignaturePanel.setVisible(myTypeComboBox.isClosureSelected()); pack(); } | itemStateChanged |
30,855 | boolean () { return GroovyApplicationSettings.getInstance().FORCE_RETURN; } | isForceReturn |
30,856 | JComponent () { JPanel north = new JPanel(); north.setLayout(new VerticalFlowLayout(VerticalFlowLayout.TOP, 0, 0, true, true)); final JPanel namePanel = createNamePanel(); namePanel.setAlignmentX(Component.LEFT_ALIGNMENT); north.add(namePanel); createCheckBoxes(north); myGetterPanel = createFieldPanel(); myGetterPanel.... | createCenterPanel |
30,857 | JPanel () { mySignature = new GrMethodSignatureComponent("", myProject); myTable = new GrParameterTablePanel() { @Override protected void updateSignature() { GrIntroduceParameterDialog.this.updateSignature(); } @Override protected void doEnterAction() { clickDefaultButton(); } @Override protected void doCancelAction() ... | createSignaturePanel |
30,858 | void () { GrIntroduceParameterDialog.this.updateSignature(); } | updateSignature |
30,859 | void () { clickDefaultButton(); } | doEnterAction |
30,860 | void () { GrIntroduceParameterDialog.this.doCancelAction(); } | doCancelAction |
30,861 | JPanel () { myDoNotReplaceRadioButton = new JBRadioButton(UIUtil.replaceMnemonicAmpersand( GroovyBundle.message("introduce.parameter.do.not.replace.option.label") )); myReplaceFieldsInaccessibleInRadioButton = new JBRadioButton(UIUtil.replaceMnemonicAmpersand( GroovyBundle.message("introduce.parameter.replace.inaccessi... | createFieldPanel |
30,862 | JPanel () { final GridBag c = new GridBag().setDefaultAnchor(GridBagConstraints.WEST).setDefaultInsets(1, 1, 1, 1); final JPanel namePanel = new JPanel(new GridBagLayout()); final JLabel typeLabel = new JLabel(UIUtil.replaceMnemonicAmpersand(GroovyBundle.message("introduce.variable.type.label"))); c.nextLine().next().w... | createNamePanel |
30,863 | void (JPanel panel) { myDeclareFinalCheckBox = new JCheckBox(UIUtil.replaceMnemonicAmpersand(GroovyBundle.message( "introduce.variable.declare.final.label"))); myDeclareFinalCheckBox.setFocusable(false); panel.add(myDeclareFinalCheckBox); myDelegateViaOverloadingMethodCheckBox = new JCheckBox(UIUtil.replaceMnemonicAmpe... | createCheckBoxes |
30,864 | GrTypeComboBox (GrVariable var, GrExpression expr, StringPartInfo stringPartInfo) { GrTypeComboBox box; if (var != null) { box = GrTypeComboBox.createTypeComboBoxWithDefType(var.getDeclaredType(), var); } else if (expr != null) { box = GrTypeComboBox.createTypeComboBoxFromExpression(expr); } else if (stringPartInfo != ... | createTypeComboBox |
30,865 | PsiType () { final ExtractClosureHelperImpl mockHelper = new ExtractClosureHelperImpl(myInfo, "__test___n_", false, new IntArrayList(), false, IntroduceParameterRefactoring.REPLACE_FIELDS_WITH_GETTERS_NONE, false, false, false); return WriteAction.compute(() -> ExtractClosureProcessorBase.generateClosure(mockHelper).ge... | inferClosureReturnType |
30,866 | NameSuggestionsField (GrVariable var) { List<String> names = new ArrayList<>(); if (var != null) { names.add(var.getName()); } names.addAll(suggestNames()); return new NameSuggestionsField(ArrayUtilRt.toStringArray(names), myProject, GroovyFileType.GROOVY_FILE_TYPE); } | createNameField |
30,867 | void (JavaRefactoringSettings settings) { final PsiField[] usedFields = GroovyIntroduceParameterUtil.findUsedFieldsWithGetters(myInfo.getStatements(), getContainingClass()); myGetterPanel.setVisible(usedFields.length > 0); switch (settings.INTRODUCE_PARAMETER_REPLACE_FIELDS_WITH_GETTERS) { case IntroduceParameterRefact... | initReplaceFieldsWithGetters |
30,868 | void () { StringBuilder b = new StringBuilder(); b.append("{ "); String[] params = ExtractUtil.getParameterString(myInfo, false); for (int i = 0; i < params.length; i++) { if (i > 0) { b.append(" "); } b.append(params[i]); b.append('\n'); } b.append(" ->\n}"); mySignature.setSignature(b.toString()); } | updateSignature |
30,869 | ValidationInfo () { final String text = getEnteredName(); if (!GroovyNamesUtil.isIdentifier(text)) { return new ValidationInfo(GroovyRefactoringBundle.message("name.is.wrong", text), myNameSuggestionsField); } if (myTypeComboBox.isClosureSelected()) { final Ref<ValidationInfo> info = new Ref<>(); for (Object2IntMap.Ent... | doValidate |
30,870 | ParameterInfo (String name) { for (ParameterInfo info : myInfo.getParameterInfos()) { if (name.equals(info.getOriginalName())) return info; } return null; } | findParamByOldName |
30,871 | PsiClass () { final GrParameterListOwner toReplaceIn = myInfo.getToReplaceIn(); if (toReplaceIn instanceof GrMethod) { return ((GrMethod)toReplaceIn).getContainingClass(); } else { return PsiTreeUtil.getContextOfType(toReplaceIn, PsiClass.class); } } | getContainingClass |
30,872 | boolean () { final Boolean createFinals = JavaRefactoringSettings.getInstance().INTRODUCE_PARAMETER_CREATE_FINALS; return createFinals == null ? JavaCodeStyleSettings.getInstance(myFile).GENERATE_FINAL_PARAMETERS : createFinals.booleanValue(); } | hasFinalModifier |
30,873 | void () { saveSettings(); super.doOKAction(); final GrParameterListOwner toReplaceIn = myInfo.getToReplaceIn(); final GrExpression expr = GroovyIntroduceParameterUtil.findExpr(myInfo); final GrVariable var = GroovyIntroduceParameterUtil.findVar(myInfo); final StringPartInfo stringPart = findStringPart(); if (myTypeComb... | doOKAction |
30,874 | String () { return myNameSuggestionsField.getEnteredName(); } | getEnteredName |
30,875 | void () { final JavaRefactoringSettings settings = JavaRefactoringSettings.getInstance(); settings.INTRODUCE_PARAMETER_CREATE_FINALS = myDeclareFinalCheckBox.isSelected(); if (myGetterPanel.isVisible()) { settings.INTRODUCE_PARAMETER_REPLACE_FIELDS_WITH_GETTERS = getReplaceFieldsWithGetter(); } if (myForceReturnCheckBo... | saveSettings |
30,876 | void (BaseRefactoringProcessor processor) { final Runnable prepareSuccessfulCallback = () -> close(DialogWrapper.OK_EXIT_CODE); processor.setPrepareSuccessfulSwingThreadCallback(prepareSuccessfulCallback); processor.setPreviewUsages(false); processor.run(); } | invokeRefactoring |
30,877 | LinkedHashSet<String> () { GrVariable var = GroovyIntroduceParameterUtil.findVar(myInfo); GrExpression expr = GroovyIntroduceParameterUtil.findExpr(myInfo); StringPartInfo stringPart = findStringPart(); return GroovyIntroduceParameterUtil.suggestNames(var, expr, stringPart, myInfo.getToReplaceIn(), myProject); } | suggestNames |
30,878 | int () { if (myDoNotReplaceRadioButton.isSelected()) return IntroduceParameterRefactoring.REPLACE_FIELDS_WITH_GETTERS_NONE; if (myReplaceFieldsInaccessibleInRadioButton.isSelected()) return IntroduceParameterRefactoring.REPLACE_FIELDS_WITH_GETTERS_INACCESSIBLE; if (myReplaceAllFieldsRadioButton.isSelected()) return Int... | getReplaceFieldsWithGetter |
30,879 | JComponent () { return myNameSuggestionsField; } | getPreferredFocusedComponent |
30,880 | String () { return HelpID.GROOVY_INTRODUCE_PARAMETER; } | getHelpId |
30,881 | IntList () { IntList list=new IntArrayList(); for (JCheckBox o : toRemoveCBs.keySet()) { if (o.isSelected()) { list.add(toRemoveCBs.getInt(o)); } } return list; } | getParametersToRemove |
30,882 | StringPartInfo () { return myInfo.getStringPartInfo(); } | findStringPart |
30,883 | void (@NotNull final Project project, final Editor editor, final PsiFile file, @Nullable final DataContext dataContext) { if (editor == null || file == null) return; final SelectionModel selectionModel = editor.getSelectionModel(); if (!selectionModel.hasSelection()) { final int offset = editor.getCaretModel().getOffse... | invoke |
30,884 | void (final GrExpression selectedValue) { invoke(project, editor, file, selectedValue.getTextRange().getStartOffset(), selectedValue.getTextRange().getEndOffset()); } | pass |
30,885 | void (@NotNull Project project, @NotNull Editor editor, @NotNull PsiFile file, int startOffset, int endOffset) { try { final InitialInfo initialInfo = GroovyExtractChooser.invoke(project, editor, file, startOffset, endOffset, false); chooseScopeAndRun(initialInfo, editor); } catch (GrRefactoringError e) { if (Applicati... | invoke |
30,886 | void (@NotNull final InitialInfo initialInfo, @NotNull final Editor editor) { final List<GrParameterListOwner> scopes = findScopes(initialInfo); if (scopes.isEmpty()) { throw new GrRefactoringError(GroovyRefactoringBundle.message("there.is.no.method.or.closure")); } else if (scopes.size() == 1 || ApplicationManager.get... | chooseScopeAndRun |
30,887 | List<GrParameterListOwner> (@NotNull InitialInfo initialInfo) { PsiElement place = initialInfo.getContext(); final List<GrParameterListOwner> scopes = new ArrayList<>(); while (true) { final GrParameterListOwner parent = PsiTreeUtil.getParentOfType(place, GrParameterListOwner.class); if (parent == null) break; scopes.a... | findScopes |
30,888 | JBPopup () { return myEnclosingMethodsPopup; } | get |
30,889 | void (@NotNull final IntroduceParameterInfo info, @NotNull final Editor editor) { if (isInplace(info, editor)) { final GrIntroduceContext context = createContext(info, editor); Map<OccurrencesChooser.ReplaceChoice, List<Object>> occurrencesMap = GrIntroduceHandlerBase.fillChoice(context); new IntroduceOccurrencesChoose... | showDialogOrStartInplace |
30,890 | void (IntroduceParameterInfo info) { new GrIntroduceParameterDialog(info).show(); } | showDialog |
30,891 | void (@NotNull final IntroduceParameterInfo info, @NotNull final GrIntroduceContext context, OccurrencesChooser.ReplaceChoice replaceChoice) { new GrInplaceParameterIntroducer(info, context, replaceChoice).startInplaceIntroduceTemplate(); } | startInplace |
30,892 | boolean (@NotNull IntroduceParameterInfo info, @NotNull Editor editor) { return GroovyIntroduceParameterUtil.findExpr(info) != null && info.getToReplaceIn() instanceof GrMethod && info.getToSearchFor() instanceof PsiMethod && GrIntroduceHandlerBase.isInplace(editor, info.getContext()); } | isInplace |
30,893 | void (@NotNull Project project, PsiElement @NotNull [] elements, DataContext dataContext) { // Does nothing } | invoke |
30,894 | GrIntroduceContext (@NotNull IntroduceParameterInfo info, @NotNull Editor editor) { GrExpression expr = GroovyIntroduceParameterUtil.findExpr(info); GrVariable var = GroovyIntroduceParameterUtil.findVar(info); StringPartInfo stringPart = info.getStringPartInfo(); return new GrIntroduceVariableHandler().getContext(info.... | createContext |
30,895 | GrExpressionWrapper (GrIntroduceParameterSettings settings) { LOG.assertTrue(settings.getToReplaceIn() instanceof GrMethod); LOG.assertTrue(settings.getToSearchFor() instanceof PsiMethod); final StringPartInfo stringPartInfo = settings.getStringPartInfo(); GrVariable var = settings.getVar(); final GrExpression expressi... | createExpressionWrapper |
30,896 | UsageViewDescriptor (final UsageInfo @NotNull [] usages) { return new UsageViewDescriptorAdapter() { @Override public PsiElement @NotNull [] getElements() { return new PsiElement[]{mySettings.getToSearchFor()}; } @Override public String getProcessedElementsHeader() { return JavaRefactoringBundle.message("introduce.para... | createUsageViewDescriptor |
30,897 | String () { return JavaRefactoringBundle.message("introduce.parameter.elements.header"); } | getProcessedElementsHeader |
30,898 | boolean (@NotNull Ref<UsageInfo[]> refUsages) { UsageInfo[] usagesIn = refUsages.get(); MultiMap<PsiElement, String> conflicts = new MultiMap<>(); if (!mySettings.generateDelegate()) { GroovyIntroduceParameterUtil.detectAccessibilityConflicts(mySettings.getExpression(), usagesIn, conflicts, mySettings.replaceFieldsWith... | preprocessUsages |
30,899 | void (UsageInfo @NotNull [] usages) { GroovyPsiElementFactory factory = GroovyPsiElementFactory.getInstance(myProject); //PsiType initializerType = mySettings.getSelectedType(); // Changing external occurrences (the tricky part) IntroduceParameterUtil.processUsages(usages, this); final GrMethod toReplaceIn = (GrMethod)... | performRefactoring |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.