Unnamed: 0 int64 0 305k | body stringlengths 7 52.9k | name stringlengths 1 185 |
|---|---|---|
285,000 | void (@NotNull AnActionEvent e) { FindManager.getInstance(getProject()).showSettingsAndFindUsages(myTargets); } | actionPerformed |
285,001 | void () { reset(); doReRun(); } | refreshUsages |
285,002 | UsageView () { myChangesDetected = false; if (myRerunAction == null) { UsageViewPresentation rerunPresentation = myPresentation.copy(); rerunPresentation.setRerunHash(System.identityHashCode(myContent)); return UsageViewManager.getInstance(getProject()). searchAndShowUsages(myTargets, myUsageSearcherFactory, true, fals... | doReRun |
285,003 | void () { ThreadingAssertions.assertEventDispatchThread(); myUsageNodes.clear(); myModel.reset(); synchronized (modelToSwingNodeChanges) { modelToSwingNodeChanges.clear(); } if (!myPresentation.isDetachedMode()) { SwingUtilities.invokeLater(() -> expandTree(2)); } } | reset |
285,004 | void (@NotNull Usage usage) { if (ApplicationManager.getApplication().isDispatchThread()) { addUpdateRequest(() -> ReadAction.run(() -> doAppendUsage(usage))); } else { doAppendUsage(usage); } } | appendUsage |
285,005 | void (@NotNull Runnable request) { updateRequests.execute(request); } | addUpdateRequest |
285,006 | void () { ApplicationManager.getApplication().assertIsNonDispatchThread(); try { ((BoundedTaskExecutor)updateRequests).waitAllTasksExecuted(10, TimeUnit.MINUTES); } catch (Exception e) { LOG.error(e); } } | waitForUpdateRequestsCompletion |
285,007 | UsageNode (@NotNull Usage usage) { ApplicationManager.getApplication().assertIsNonDispatchThread(); // invoke in ReadAction to be sure that usages are not invalidated while the tree is being built ApplicationManager.getApplication().assertReadAccessAllowed(); if (!usage.isValid()) { // because the view is built increme... | doAppendUsage |
285,008 | void (@NotNull PsiElementUsage usage) { Class<? extends PsiReference> referenceClass = UsageReferenceClassProvider.Companion.getReferenceClass(usage); PsiElement element = usage.getElement(); if (element != null && referenceClass != null) { Language language = element.getLanguage(); if (myReportedReferenceClasses.add(P... | reportToFUS |
285,009 | void (@NotNull Usage usage) { removeUsagesBulk(Collections.singleton(usage)); } | removeUsage |
285,010 | void (@NotNull Collection<? extends Usage> usages) { Usage toSelect = getNextToSelect(usages); UsageNode nodeToSelect = toSelect != null ? myUsageNodes.get(toSelect) : null; Set<UsageNode> nodes = usagesToNodes(usages.stream()).collect(Collectors.toSet()); usages.forEach(myUsageNodes::remove); if (!myUsageNodes.isEmpty... | removeUsagesBulk |
285,011 | void (Usage @NotNull [] usages) { usagesToNodes(Arrays.stream(usages)) .forEach(myExclusionHandler::includeNode); } | includeUsages |
285,012 | void (Usage @NotNull [] usages) { usagesToNodes(Arrays.stream(usages)) .forEach(myExclusionHandler::excludeNode); } | excludeUsages |
285,013 | Stream<UsageNode> (@NotNull Stream<? extends Usage> usages) { return usages .map(myUsageNodes::get) .filter(node -> node != NULL_NODE && node != null); } | usagesToNodes |
285,014 | void (Usage @NotNull [] usages) { ThreadingAssertions.assertEventDispatchThread(); TreePath[] paths = usagesToNodes(Arrays.stream(usages)) .map(node -> new TreePath(node.getPath())) .toArray(TreePath[]::new); myTree.setSelectionPaths(paths); if (paths.length != 0) myTree.scrollPathToVisible(paths[0]); } | selectUsages |
285,015 | JComponent () { ThreadingAssertions.assertEventDispatchThread(); return myTree != null ? myTree : getComponent(); } | getPreferredFocusableComponent |
285,016 | JComponent () { ThreadingAssertions.assertEventDispatchThread(); return myRootPanel == null ? new JLabel() : myRootPanel; } | getComponent |
285,017 | int () { return myUsageNodes.size(); } | getUsagesCount |
285,018 | void (@NotNull Disposable disposable, @NotNull ExcludeListener listener) { myExcludeListeners.add(listener); Disposer.register(disposable, () -> myExcludeListeners.remove(listener)); } | addExcludeListener |
285,019 | void () { ThreadingAssertions.assertEventDispatchThread(); if (isDisposed()) return; TreeNode root = (TreeNode)myTree.getModel().getRoot(); List<Node> toUpdate = new ArrayList<>(); checkNodeValidity(root, new TreePath(root), toUpdate); queueUpdateBulk(toUpdate, EmptyRunnable.getInstance()); updateOnSelectionChanged(); ... | updateImmediately |
285,020 | void (@NotNull List<? extends Node> toUpdate, @NotNull Runnable onCompletedInEdt) { if (toUpdate.isEmpty() || isDisposed()) return; ReadAction .nonBlocking(() -> { for (Node node : toUpdate) { try { node.update(edtFireTreeNodesChangedQueue); } catch (IndexNotReadyException ignore) { } } }) .expireWith(this) .finishOnUi... | queueUpdateBulk |
285,021 | void (@NotNull Collection<? extends Node> nodes) { ThreadingAssertions.assertEventDispatchThread(); if (isDisposed()) return; TreeNode root = (TreeNode)myTree.getModel().getRoot(); Set<Node> queued = new HashSet<>(); List<Node> toUpdate = new ArrayList<>(); while (true) { Set<Node> parents = new HashSet<>(); for (Node ... | updateImmediatelyNodesUpToRoot |
285,022 | void () { ThreadingAssertions.assertEventDispatchThread(); if (myCurrentUsageContextPanel != null) { try { myCurrentUsageContextPanel.updateLayout(ContainerUtil.notNullize(getSelectedUsageInfos()), this); } catch (IndexNotReadyException ignore) { } } } | updateOnSelectionChanged |
285,023 | void (@NotNull TreeNode node, @NotNull TreePath path, @NotNull List<? super Node> result) { ThreadingAssertions.assertEventDispatchThread(); boolean shouldCheckChildren = true; if (myTree.isCollapsed(path)) { if (node instanceof Node) { ((Node)node).markNeedUpdate(); } shouldCheckChildren = false; // optimization: do n... | checkNodeValidity |
285,024 | void () { cancelCurrentSearch(); if (myContent != null) { UsageViewContentManager.getInstance(myProject).closeContent(myContent); } } | close |
285,025 | void () { ThreadingAssertions.assertEventDispatchThread(); getUsageViewSettings().setPreviewUsagesSplitterProportion(myPreviewSplitter.getProportion()); } | saveSplitterProportions |
285,026 | void () { ThreadingAssertions.assertEventDispatchThread(); disposeUsageContextPanels(); isDisposed = true; myUpdateAlarm.cancelAllRequests(); fusRunnable = null; // Release reference to this cancelCurrentSearch(); myRerunAction = null; if (myTree != null) { ToolTipManager.sharedInstance().unregisterComponent(myTree); }... | dispose |
285,027 | void () { List<SmartPsiElementPointer<?>> smartPointers = new ArrayList<>(); for (Usage usage : myUsageNodes.keySet()) { if (usage instanceof UsageInfo2UsageAdapter) { SmartPsiElementPointer<?> pointer = ((UsageInfo2UsageAdapter)usage).getUsageInfo().getSmartPointer(); smartPointers.add(pointer); } } if (!smartPointers... | disposeSmartPointers |
285,028 | boolean () { return mySearchInProgress; } | isSearchInProgress |
285,029 | void (boolean searchInProgress) { mySearchInProgress = searchInProgress; if (!myPresentation.isDetachedMode()) { UIUtil.invokeLaterIfNeeded(() -> { if (isDisposed()) return; if (userHasSelectedNode()) return; Node nodeToSelect = ObjectUtils.coalesce(myAutoSelectedGroupNode, myModel.getFirstUsageNode()); if (nodeToSelec... | setSearchInProgress |
285,030 | boolean () { GroupNode autoSelectedGroupNode = myAutoSelectedGroupNode; Node selectedNode = getSelectedNode(); if (selectedNode != null) { TreePath expectedPathToBeSelected = autoSelectedGroupNode != null ? TreeUtil.getPathFromRoot(autoSelectedGroupNode) : TreeUtil.getFirstNodePath(myTree); if (!Comparing.equal(TreeUti... | userHasSelectedNode |
285,031 | boolean () { return isDisposed || myProject.isDisposed(); } | isDisposed |
285,032 | void (@NotNull Node node) { ThreadingAssertions.assertEventDispatchThread(); if (!isDisposed() && !myPresentation.isDetachedMode()) { fireEvents(); TreePath usagePath = new TreePath(node.getPath()); myTree.expandPath(usagePath.getParentPath()); TreeUtil.selectPath(myTree, usagePath); } } | showNode |
285,033 | void (@NotNull Action rerunAction) { myRerunAction = rerunAction; } | setRerunAction |
285,034 | void (@NotNull Action action) { ThreadingAssertions.assertEventDispatchThread(); int index = myButtonPanel.getComponentCount(); if (!SystemInfo.isMac && index > 0 && myPresentation.isShowCancelButton()) index--; myButtonPanel.addButtonAction(index, action); Object o = action.getValue(Action.ACCELERATOR_KEY); if (o inst... | addButtonToLowerPane |
285,035 | void (@NotNull Runnable runnable, @NotNull @NlsContexts.Button String text) { addButtonToLowerPane(new AbstractAction(UIUtil.replaceMnemonicAmpersand(text)) { @Override public void actionPerformed(ActionEvent e) { runnable.run(); } }); } | addButtonToLowerPane |
285,036 | void (ActionEvent e) { runnable.run(); } | actionPerformed |
285,037 | void (@Nullable JComponent comp) { BorderLayout layout = (BorderLayout)myAdditionalComponent.getLayout(); Component prev = layout.getLayoutComponent(myAdditionalComponent, BorderLayout.CENTER); if (prev == comp) return; if (prev != null) myAdditionalComponent.remove(prev); if (comp != null) myAdditionalComponent.add(co... | setAdditionalComponent |
285,038 | void (@NotNull Runnable runnable, @NotNull @NlsContexts.Button String text, char mnemonic) { // implemented method is deprecated, so, it just calls non-deprecated overloading one addButtonToLowerPane(runnable, text); } | addButtonToLowerPane |
285,039 | void (@NotNull Runnable processRunnable, @Nullable @NlsContexts.Command String commandName, @NotNull @NlsContexts.DialogMessage String cannotMakeString, @NotNull @NlsContexts.Button String shortDescription) { addPerformOperationAction(processRunnable, commandName, cannotMakeString, shortDescription, true); } | addPerformOperationAction |
285,040 | void (@NotNull Runnable processRunnable, @Nullable @NlsContexts.Command String commandName, @NotNull @NlsContexts.DialogMessage String cannotMakeString, @NotNull @NlsContexts.Button String shortDescription, boolean checkReadOnlyStatus) { Runnable runnable = new MyPerformOperationRunnable(processRunnable, commandName, c... | addPerformOperationAction |
285,041 | boolean () { for (UsageTarget target : myTargets) { if (!target.isValid()) { return false; } } return true; } | allTargetsAreValid |
285,042 | UsageViewPresentation () { return myPresentation; } | getPresentation |
285,043 | boolean () { if (myRerunAction != null && myRerunAction.isEnabled()) return allTargetsAreValid(); try { return myUsageSearcherFactory != null && allTargetsAreValid() && myUsageSearcherFactory.create() != null; } catch (PsiInvalidElementAccessException e) { return false; } } | canPerformReRun |
285,044 | boolean () { Set<VirtualFile> readOnlyUsages = getReadOnlyUsagesFiles(); return readOnlyUsages.isEmpty() || !ReadonlyStatusHandler.getInstance(myProject).ensureFilesWritable(readOnlyUsages).hasReadonlyFiles(); } | checkReadonlyUsages |
285,045 | Set<Usage> () { Set<Usage> result = new HashSet<>(); Set<Map.Entry<Usage, UsageNode>> usages = myUsageNodes.entrySet(); for (Map.Entry<Usage, UsageNode> entry : usages) { Usage usage = entry.getKey(); UsageNode node = entry.getValue(); if (node != null && node != NULL_NODE && !node.isExcluded() && usage.isReadOnly()) {... | getReadOnlyUsages |
285,046 | Set<VirtualFile> () { Set<Usage> usages = getReadOnlyUsages(); Set<VirtualFile> result = new HashSet<>(); for (Usage usage : usages) { if (usage instanceof UsageInFile usageInFile) { VirtualFile file = usageInFile.getFile(); if (file != null && file.isValid()) result.add(file); } if (usage instanceof UsageInFiles usage... | getReadOnlyUsagesFiles |
285,047 | Set<Usage> () { Set<Usage> result = new HashSet<>(); for (Map.Entry<Usage, UsageNode> entry : myUsageNodes.entrySet()) { UsageNode node = entry.getValue(); Usage usage = entry.getKey(); if (node == NULL_NODE || node == null) { continue; } if (node.isExcluded()) { result.add(usage); } } return result; } | getExcludedUsages |
285,048 | Node () { ThreadingAssertions.assertEventDispatchThread(); TreePath path = myTree.getLeadSelectionPath(); Object node = path == null ? null : path.getLastPathComponent(); return node instanceof Node ? (Node)node : null; } | getSelectedNode |
285,049 | List<TreeNode> () { ThreadingAssertions.assertEventDispatchThread(); TreePath[] selectionPaths = myTree.getSelectionPaths(); return selectionPaths == null ? Collections.emptyList() : ContainerUtil.mapNotNull(selectionPaths, p-> ObjectUtils.tryCast(p.getLastPathComponent(), TreeNode.class)); } | selectedNodes |
285,050 | Set<Usage> () { ThreadingAssertions.assertEventDispatchThread(); return new HashSet<>(allUsagesRecursive(selectedNodes())); } | getSelectedUsages |
285,051 | Set<Usage> () { return myUsageNodes.keySet(); } | getUsages |
285,052 | List<Usage> () { List<Usage> usages = new ArrayList<>(getUsages()); usages.sort(USAGE_COMPARATOR_BY_FILE_AND_OFFSET); return usages; } | getSortedUsages |
285,053 | Navigatable (@NotNull DefaultMutableTreeNode node, boolean allowRequestFocus) { Object userObject = node.getUserObject(); if (userObject instanceof Navigatable navigatable) { return navigatable.canNavigate() ? new Navigatable() { @Override public void navigate(boolean requestFocus) { if (Registry.is("ide.usages.next.pr... | getNavigatableForNode |
285,054 | void (boolean requestFocus) { if (Registry.is("ide.usages.next.previous.occurrence.only.show.in.preview") && isPreviewUsages() && myRootPanel.isShowing()) select(); else navigatable.navigate(allowRequestFocus && requestFocus); } | navigate |
285,055 | boolean () { return navigatable.canNavigate(); } | canNavigate |
285,056 | boolean () { return navigatable.canNavigateToSource(); } | canNavigateToSource |
285,057 | Navigatable (@NotNull DefaultMutableTreeNode node) { if (node.getChildCount() > 0) return null; if (node instanceof Node && ((Node)node).isExcluded()) return null; return getNavigatableForNode(node, !myPresentation.isReplaceMode()); } | createDescriptorForNode |
285,058 | String () { return UsageViewBundle.message("action.next.occurrence"); } | getNextOccurenceActionName |
285,059 | String () { return UsageViewBundle.message("action.previous.occurrence"); } | getPreviousOccurenceActionName |
285,060 | ActionUpdateThread () { return ActionUpdateThread.EDT; } | getActionUpdateThread |
285,061 | Collection<String> () { List<String> lines = ContainerUtil.mapNotNull(selectedNodes(), o -> o instanceof Node ? ((Node)o).getNodeText() : null); return lines.isEmpty() ? null : lines; } | getTextLinesToCopy |
285,062 | void (FocusEvent e) { super.processFocusEvent(e); if (e.getID() == FocusEvent.FOCUS_GAINED) { transferFocus(); } } | processFocusEvent |
285,063 | void () { mySupport = null; } | dispose |
285,064 | boolean () { return mySupport != null && mySupport.hasNextOccurence(); } | hasNextOccurence |
285,065 | boolean () { return mySupport != null && mySupport.hasPreviousOccurence(); } | hasPreviousOccurence |
285,066 | OccurenceInfo () { return mySupport != null ? mySupport.goNextOccurence() : null; } | goNextOccurence |
285,067 | OccurenceInfo () { return mySupport != null ? mySupport.goPreviousOccurence() : null; } | goPreviousOccurence |
285,068 | String () { return mySupport != null ? mySupport.getNextOccurenceActionName() : ""; } | getNextOccurenceActionName |
285,069 | String () { return mySupport != null ? mySupport.getPreviousOccurenceActionName() : ""; } | getPreviousOccurenceActionName |
285,070 | Object (@NotNull String dataId) { if (CommonDataKeys.PROJECT.is(dataId)) { return myProject; } else if (USAGE_VIEW_KEY.is(dataId)) { return UsageViewImpl.this; } else if (PlatformCoreDataKeys.HELP_ID.is(dataId)) { return HELP_ID; } else if (PlatformDataKeys.COPY_PROVIDER.is(dataId)) { return myCopyProvider; } else if (... | getData |
285,071 | void () { update(); } | enteredDumbMode |
285,072 | void () { update(); } | exitDumbMode |
285,073 | void (int index, @NotNull Action action) { JButton button = new JButton(action); add(button, index); DialogUtil.registerMnemonic(button); if (getBorder() == null) setBorder(IdeBorderFactory.createBorder(SideBorder.TOP)); update(); Object s = action.getValue(Action.LONG_DESCRIPTION); if (s instanceof String) { JBLabel l... | addButtonAction |
285,074 | void () { ThreadingAssertions.assertEventDispatchThread(); UsageNode node = myUsageNodes.get(myUsage); if (node == NULL_NODE || node == null) { return; } DefaultMutableTreeNode parentGroupingNode = (DefaultMutableTreeNode)node.getParent(); if (parentGroupingNode != null) { TreePath treePath = new TreePath(parentGroupin... | restore |
285,075 | void () { if (myCheckReadOnlyStatus && !checkReadonlyUsages()) return; PsiDocumentManager.getInstance(myProject).commitAllDocuments(); if (myCannotMakeString != null && !myCannotMakeString.isEmpty() && myChangesDetected) { String title = UsageViewBundle.message("changes.detected.error.title"); if (canPerformReRun()) { ... | run |
285,076 | List<UsageInfo> () { ThreadingAssertions.assertEventDispatchThread(); return USAGE_INFO_LIST_KEY.getData(DataManager.getInstance().getDataContext(myRootPanel)); } | getSelectedUsageInfos |
285,077 | GroupNode () { return myRoot; } | getRoot |
285,078 | String (@NotNull TreeNode node) { return myUsageViewTreeCellRenderer.getPlainTextForNode(node); } | getNodeText |
285,079 | boolean (@NotNull Usage usage) { return myBuilder != null && myBuilder.isVisible(usage); } | isVisible |
285,080 | boolean () { return myPresentation.isMergeDupLinesAvailable() && getUsageViewSettings().isFilterDuplicatedLine(); } | isFilterDuplicateLines |
285,081 | Usage (@NotNull Usage toDelete) { ThreadingAssertions.assertEventDispatchThread(); UsageNode usageNode = myUsageNodes.get(toDelete); if (usageNode == null || usageNode.getParent().getChildCount() == 0) return null; DefaultMutableTreeNode node = myRootPanel.mySupport.findNextNodeAfter(myTree, usageNode, true); if (node ... | getNextToSelect |
285,082 | Usage (@NotNull Collection<? extends Usage> toDelete) { ThreadingAssertions.assertEventDispatchThread(); Usage toSelect = null; for (Usage usage : toDelete) { Usage next = getNextToSelect(usage); if (next != null && !toDelete.contains(next)) { toSelect = next; break; } } return toSelect; } | getNextToSelect |
285,083 | KeyboardShortcut () { return UsageViewUtil.getShowUsagesWithSettingsShortcut(); } | getShowUsagesWithSettingsShortcut |
285,084 | boolean () { return true; } | isDataValid |
285,085 | boolean () { return true; } | isDataReadOnly |
285,086 | boolean () { return false; } | isDataExcluded |
285,087 | String () { return getUserObject().toString(); } | getNodeText |
285,088 | void () { if (myTargetsNode == null || myTargets.length == 0) { return; } ThreadingAssertions.assertEventDispatchThread(); myTargetNodes = new UsageTargetNode[myTargets.length]; myTargetsNode.removeAllChildren(); for (int i = 0; i < myTargets.length; i++) { UsageTarget target = myTargets[i]; UsageTargetNode targetNode ... | addTargetNodes |
285,089 | TreeNode (@NotNull TreeNode parent, @NotNull Class<?> type) { int childCount = parent.getChildCount(); for (int idx = 0; idx < childCount; idx++) { TreeNode child = parent.getChildAt(idx); if (type.isAssignableFrom(child.getClass())) { return child; } TreeNode firstChildOfType = getFirstChildOfType(child, type); if (fi... | getFirstChildOfType |
285,090 | Object () { return myRootNode; } | getRoot |
285,091 | void (TreeNode node) { ThreadingAssertions.assertEventDispatchThread(); super.nodeChanged(node); } | nodeChanged |
285,092 | void (TreeNode node, int[] childIndices) { ThreadingAssertions.assertEventDispatchThread(); super.nodesWereInserted(node, childIndices); } | nodesWereInserted |
285,093 | void (TreeNode node, int[] childIndices, Object[] removedChildren) { ThreadingAssertions.assertEventDispatchThread(); super.nodesWereRemoved(node, childIndices, removedChildren); } | nodesWereRemoved |
285,094 | void (TreeNode node, int[] childIndices) { ThreadingAssertions.assertEventDispatchThread(); super.nodesChanged(node, childIndices); } | nodesChanged |
285,095 | void (TreeNode node) { ThreadingAssertions.assertEventDispatchThread(); super.nodeStructureChanged(node); } | nodeStructureChanged |
285,096 | void (Object source, Object[] path, int[] childIndices, Object[] children) { ThreadingAssertions.assertEventDispatchThread(); super.fireTreeNodesChanged(source, path, childIndices, children); } | fireTreeNodesChanged |
285,097 | void (Object source, Object[] path, int[] childIndices, Object[] children) { ThreadingAssertions.assertEventDispatchThread(); super.fireTreeNodesInserted(source, path, childIndices, children); } | fireTreeNodesInserted |
285,098 | void (Object source, Object[] path, int[] childIndices, Object[] children) { ThreadingAssertions.assertEventDispatchThread(); super.fireTreeNodesRemoved(source, path, childIndices, children); } | fireTreeNodesRemoved |
285,099 | void (Object source, Object[] path, int[] childIndices, Object[] children) { ThreadingAssertions.assertEventDispatchThread(); super.fireTreeStructureChanged(source, path, childIndices, children); } | fireTreeStructureChanged |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.