Unnamed: 0
int64
0
305k
body
stringlengths
7
52.9k
name
stringlengths
1
185
6,000
void (@NlsContexts.ProgressText String s) { final ProgressIndicator progress = myProgress.get(); if (progress != null) { progress.setText2(s); } }
setProgressStatistics
6,001
void (@NlsContexts.ProgressText String s) { final ProgressIndicator progress = myProgress.get(); if (progress != null) { progress.setText(s); } }
setProgressText
6,002
void (@Nls String text) { myMessageView.outputError(text, AntBuildMessageView.PRIORITY_ERR); }
printRawError
6,003
void (@NlsSafe String text) { if (!myFirstLineProcessed) { myFirstLineProcessed = true; myStartedSuccessfully = false; myMessageView.buildFailed(myBuildName); } if (!myStartedSuccessfully) { printRawError(text); } }
readErrorOutput
6,004
void (char tagName, @NlsSafe final String tagValue, @AntMessage.Priority int priority) { if (LOG.isDebugEnabled()) { LOG.debug(String.valueOf(tagName) + priority + "=" + tagValue); } if (IdeaAntLogger2.TARGET == tagName) { setProgressStatistics(AntBundle.message("target.tag.name.status.text", tagValue)); } else if (Ide...
processTag
6,005
int (int priority) { if (priority == AntBuildMessageView.PRIORITY_ERR || priority == AntBuildMessageView.PRIORITY_WARN || priority == AntBuildMessageView.PRIORITY_INFO || priority == AntBuildMessageView.PRIORITY_VERBOSE || priority == AntBuildMessageView.PRIORITY_DEBUG) { return priority; } return AntBuildMessageView.P...
fixPriority
6,006
void (final List<String> javacMessages, final AntBuildMessageView messageView, final Project project) { if (javacMessages == null) { return; } final com.intellij.compiler.OutputParser outputParser = new JavacOutputParser(project); com.intellij.compiler.OutputParser.Callback callback = new com.intellij.compiler.OutputPa...
processJavacMessages
6,007
String () { if (myIndex >= javacMessages.size()) { return null; } return javacMessages.get(myIndex); }
getCurrentLine
6,008
String () { final int size = javacMessages.size(); final int next = Math.min(myIndex + 1, javacMessages.size()); myIndex = next; if (next >= size) { return null; } return javacMessages.get(next); }
getNextLine
6,009
void (String line) { myIndex--; }
pushBack
6,010
void (final CompilerMessageCategory category, final String message, final String url, final int lineNum, final int columnNum) { StringTokenizer tokenizer = new StringTokenizer(message, "\n", false); final String[] strings = new String[tokenizer.countTokens()]; for (int idx = 0; tokenizer.hasMoreTokens(); idx++) { strin...
message
6,011
void (String text) { }
setProgressText
6,012
void (String path) { }
fileProcessed
6,013
void (String path) { }
fileGenerated
6,014
String (SegmentReader reader, Project project) { String prompt = reader.readLimitedString(); String defaultValue = reader.readLimitedString(); String[] choices = reader.readStringArray(); MessagesEx.BaseInputInfo question; if (choices.length == 0) { MessagesEx.InputInfo inputInfo = new MessagesEx.InputInfo(project); in...
askUser
6,015
String () { return "#com.intellij.ant.explorer.SaveMetaTargetDialog"; }
getDimensionServiceKey
6,016
void () { final ExecuteCompositeTargetEvent eventObject = createEventObject(); if (myAntConfiguration.getTargetForEvent(eventObject) == null) { myAntConfiguration.setTargetForEvent(myBuildFile, eventObject.getMetaTargetName(), eventObject); super.doOKAction(); } else { Messages.showInfoMessage(getContentPane(), AntBund...
doOKAction
6,017
JComponent () { return myTfName; }
getPreferredFocusedComponent
6,018
JComponent () { final JPanel panel = new JPanel(new GridBagLayout()); final JLabel nameLabel = new JLabel(AntBundle.message("save.meta.data.name.label")); panel.add(nameLabel, new GridBagConstraints(0, GridBagConstraints.RELATIVE, 1, 1, 0.0, 0.0, GridBagConstraints.NORTHWEST, GridBagConstraints.NONE, JBInsets.emptyInse...
createCenterPanel
6,019
void (ActionEvent e) { upButton.setEnabled(ListUtil.canMoveSelectedItemsUp(myTargetList)); downButton.setEnabled(ListUtil.canMoveSelectedItemsDown(myTargetList)); }
actionPerformed
6,020
void (ActionEvent e) { ListUtil.moveSelectedItemsUp(myTargetList); super.actionPerformed(e); }
actionPerformed
6,021
void (ActionEvent e) { ListUtil.moveSelectedItemsDown(myTargetList); super.actionPerformed(e); }
actionPerformed
6,022
void (ListSelectionEvent e) { upButton.setEnabled(ListUtil.canMoveSelectedItemsUp(myTargetList)); downButton.setEnabled(ListUtil.canMoveSelectedItemsDown(myTargetList)); }
valueChanged
6,023
ExecuteCompositeTargetEvent () { final ListModel model = myTargetList.getModel(); final int size = model.getSize(); final List<@NlsSafe String> names = new ArrayList<>(); for (int idx = 0; idx < size; idx++) { names.add((String)model.getElementAt(idx)); } final ExecuteCompositeTargetEvent event = new ExecuteCompositeTa...
createEventObject
6,024
boolean (@NotNull JTree tree) { final AntConfiguration config = myConfig; return config != null && !config.getBuildFileList().isEmpty() && super.isEnabled(tree); }
isEnabled
6,025
void () { treeModel.invalidateAsync(); }
configurationLoaded
6,026
void (AntBuildFile buildFile) { treeModel.invalidateAsync(); }
buildFileAdded
6,027
void (AntBuildFile buildFile) { treeModel.invalidate(buildFile, true); }
buildFileChanged
6,028
void (AntBuildFile buildFile) { treeModel.invalidateAsync(); }
buildFileRemoved
6,029
void () { config.removeAntConfigurationListener(listener); }
dispose
6,030
void (final Component comp, final int x, final int y) { popupInvoked(comp, x, y); }
invokePopup
6,031
void (@NotNull MouseEvent e, @NotNull DataContext dataContext, @NotNull TreePath treePath) { runSelection(DataManager.getInstance().getDataContext(myTree), true); }
processDoubleClick
6,032
void (ActionEvent e) { runSelection(DataManager.getInstance().getDataContext(myTree), false); }
actionPerformed
6,033
void (@NotNull Keymap keymap) { treeModel.invalidateAsync(); }
keymapAdded
6,034
void (@NotNull Keymap keymap) { treeModel.invalidateAsync(); }
keymapRemoved
6,035
void (@Nullable Keymap keymap) { treeModel.invalidateAsync(); }
activeKeymapChanged
6,036
void (@NotNull Keymap keymap, @NotNull String actionId) { treeModel.invalidateAsync(); }
shortcutChanged
6,037
void () { treeModel.invalidateAsync(); }
beforeRunTasksChanged
6,038
void () { StatusText emptyText = myTree.getEmptyText(); emptyText.appendLine(AntBundle.message("ant.empty.text.1")); emptyText.appendLine(AntBundle.message("ant.empty.text.2"), SimpleTextAttributes.LINK_PLAIN_ATTRIBUTES, e -> addBuildFile()); emptyText.appendLine(""); emptyText.appendLine( AllIcons.General.ContextHelp,...
setupEmptyText
6,039
void () { final Tree tree = myTree; if (tree != null) { ToolTipManager.sharedInstance().unregisterComponent(tree); for (KeyStroke keyStroke : tree.getRegisteredKeyStrokes()) { tree.unregisterKeyboardAction(keyStroke); } myTree = null; } myTreeModel = null; myProject = null; myConfig = null; }
dispose
6,040
JPanel () { final DefaultActionGroup group = new DefaultActionGroup(); group.add(new AddAction()); group.add(new RemoveAction()); group.add(new RunAction()); group.add(new ShowAllTargetsAction()); AnAction action = CommonActionsManager.getInstance().createExpandAllAction(myTreeExpander, this); action.getTemplatePresent...
createToolbarPanel
6,041
void () { final FileChooserDescriptor descriptor = createXmlDescriptor(); descriptor.setTitle(AntBundle.message("select.ant.build.file.dialog.title")); descriptor.setDescription(AntBundle.message("select.ant.build.file.dialog.description")); final VirtualFile[] files = FileChooser.chooseFiles(descriptor, myProject, nul...
addBuildFile
6,042
void (final VirtualFile[] files) { if (files.length == 0) { return; } ApplicationManager.getApplication().invokeLater(() -> { final AntConfiguration antConfiguration = myConfig; if (antConfiguration == null) { return; } final List<VirtualFile> ignoredFiles = new ArrayList<>(); for (VirtualFile file : files) { try { ant...
addBuildFile
6,043
void () { final Collection<AntBuildFileBase> files = getSelectedBuildFiles(); if (!files.isEmpty()) { if (files.size() == 1) { removeBuildFile(files.iterator().next()); } else { String dialogTitle = AntBundle.message("dialog.title.confirm.remove"); String message = AntBundle.message("dialog.message.remove.build.files.r...
removeSelectedBuildFiles
6,044
void () { final AntBuildFile buildFile = getCurrentBuildFile(); if (buildFile == null) { return; } removeBuildFile(buildFile); }
removeBuildFile
6,045
void (AntBuildFile buildFile) { final String fileName = buildFile.getPresentableUrl(); final int result = Messages.showYesNoDialog(myProject, AntBundle.message("remove.the.reference.to.file.confirmation.text", fileName), AntBundle.message("dialog.title.confirm.remove"), Messages.getQuestionIcon()); if (result != Messag...
removeBuildFile
6,046
void () { final AntBuildFileBase buildFile = getCurrentBuildFile(); if (buildFile != null && BuildFilePropertiesPanel.editBuildFile(buildFile)) { myConfig.updateBuildFile(buildFile); } }
setBuildFileProperties
6,047
void (final DataContext dataContext, final boolean moveFocusToEditor) { if (!canRunSelection()) { return; } final AntBuildFileBase buildFile = getCurrentBuildFile(); if (buildFile != null) { final List<String> targets = getTargetNamesFromPaths(myTree.getSelectionPaths()); AntActionsUsagesCollector.runSelectedBuildActio...
runSelection
6,048
boolean () { if (myTree == null) { return false; } final TreePath[] paths = myTree.getSelectionPaths(); if (paths == null) { return false; } final AntBuildFile buildFile = getCurrentBuildFile(); if (buildFile == null || !buildFile.exists()) { return false; } for (final TreePath path : paths) { final DefaultMutableTreeN...
canRunSelection
6,049
AntBuildTarget[] (TreePath[] paths) { return Arrays.stream(paths) .map(path -> ((DefaultMutableTreeNode)path.getLastPathComponent()).getUserObject()) .filter(userObject -> userObject instanceof AntTargetNodeDescriptor) .map(userObject -> ((AntTargetNodeDescriptor)userObject).getTarget()) .toArray(AntBuildTarget[]::new)...
getTargetObjectsFromPaths
6,050
AntBuildFileBase () { if( myProject == null) return null; return getCurrentBuildFile(); }
getSelectedFile
6,051
AntBuildFileBase () { final AntBuildFileNodeDescriptor descriptor = getCurrentBuildFileNodeDescriptor(); return (AntBuildFileBase)((descriptor == null) ? null : descriptor.getBuildFile()); }
getCurrentBuildFile
6,052
Collection<AntBuildFileBase> () { if (myTree == null) { return Collections.emptyList(); } final TreePath[] paths = myTree.getSelectionPaths(); if (paths == null) { return Collections.emptyList(); } final Set<AntBuildFileBase> result = new HashSet<>(); for (TreePath path : paths) { DefaultMutableTreeNode node = (Default...
getSelectedBuildFiles
6,053
AntBuildFileNodeDescriptor () { final Tree tree = myTree; if (tree == null) { return null; } final TreePath path = tree.getSelectionPath(); if (path == null) { return null; } DefaultMutableTreeNode node = (DefaultMutableTreeNode)path.getLastPathComponent(); while (node != null) { final Object userObject = node.getUserO...
getCurrentBuildFileNodeDescriptor
6,054
void (final Component comp, final int x, final int y) { Object userObject = null; final TreePath path = myTree.getSelectionPath(); if (path != null) { final DefaultMutableTreeNode node = (DefaultMutableTreeNode)path.getLastPathComponent(); if (node != null) { userObject = node.getUserObject(); } } final DefaultActionGr...
popupInvoked
6,055
Object (@NotNull @NonNls String dataId) { if (PlatformCoreDataKeys.BGT_DATA_PROVIDER.is(dataId)) { Tree tree = myTree; if (tree == null) { return null; } final TreePath[] paths = tree.getSelectionPaths(); final TreePath leadPath = tree.getLeadSelectionPath(); final AntBuildFile currentBuildFile = getCurrentBuildFile();...
getData
6,056
Object (@NotNull @NonNls String dataId, final TreePath @Nullable [] paths, @Nullable TreePath leadPath, @Nullable AntBuildFile currentBuildFile) { if (CommonDataKeys.VIRTUAL_FILE_ARRAY.is(dataId)) { final List<VirtualFile> virtualFiles = collectAntFiles(buildFile -> { final VirtualFile virtualFile = buildFile.getVirtua...
getSlowData
6,057
FileChooserDescriptor () { return new FileChooserDescriptor(true, false, false, false, false, true){ @Override public boolean isFileVisible(VirtualFile file, boolean showHiddenFiles) { boolean b = super.isFileVisible(file, showHiddenFiles); if (!file.isDirectory()) { b &= FileTypeRegistry.getInstance().isFileOfType(fil...
createXmlDescriptor
6,058
boolean (VirtualFile file, boolean showHiddenFiles) { boolean b = super.isFileVisible(file, showHiddenFiles); if (!file.isDirectory()) { b &= FileTypeRegistry.getInstance().isFileOfType(file, XmlFileType.INSTANCE); } return b; }
isFileVisible
6,059
void (@NotNull JTree tree, Object value, boolean selected, boolean expanded, boolean leaf, int row, boolean hasFocus) { final Object userObject = ((DefaultMutableTreeNode)value).getUserObject(); if (userObject instanceof AntNodeDescriptor descriptor) { descriptor.customize(this); } else { append(tree.convertValueToText...
customizeCellRenderer
6,060
void (@NotNull AnActionEvent e) { addBuildFile(); }
actionPerformed
6,061
void (@NotNull AnActionEvent e) { removeSelectedBuildFiles(); }
actionPerformed
6,062
void (@NotNull AnActionEvent event) { event.getPresentation().setEnabled(getCurrentBuildFile() != null); }
update
6,063
ActionUpdateThread () { return ActionUpdateThread.EDT; }
getActionUpdateThread
6,064
void (@NotNull AnActionEvent e) { runSelection(e.getDataContext(), true); }
actionPerformed
6,065
void (@NotNull AnActionEvent event) { final Presentation presentation = event.getPresentation(); final String place = event.getPlace(); if (ActionPlaces.ANT_EXPLORER_TOOLBAR.equals(place)) { presentation.setText(AntBundle.messagePointer("run.ant.file.or.target.action.name")); } else { final TreePath[] paths = myTree.ge...
update
6,066
ActionUpdateThread () { return ActionUpdateThread.EDT; }
getActionUpdateThread
6,067
void (@NotNull AnActionEvent e) { final Presentation presentation = e.getPresentation(); presentation.setEnabled(myTree.getSelectionCount() == 1 && canRunSelection()); }
update
6,068
ActionUpdateThread () { return ActionUpdateThread.EDT; }
getActionUpdateThread
6,069
void (@NotNull AnActionEvent e) { final AntBuildFile buildFile = getCurrentBuildFile(); if (buildFile == null || !buildFile.exists()) { return; } TreePath selectionPath = myTree.getSelectionPath(); if (selectionPath == null) return; final DefaultMutableTreeNode node = (DefaultMutableTreeNode) selectionPath.getLastPathC...
actionPerformed
6,070
boolean (@NotNull AnActionEvent event) { final Project project = myProject; return project != null && AntConfigurationBase.getInstance(project).isFilterTargets(); }
isSelected
6,071
void (@NotNull AnActionEvent event, boolean flag) { setTargetsFiltered(flag); }
setSelected
6,072
ActionUpdateThread () { return ActionUpdateThread.BGT; }
getActionUpdateThread
6,073
void (boolean value) { try { myTreeStructure.setFilteredTargets(value); AntConfigurationBase.getInstance(myProject).setFilterTargets(value); } finally { myTreeModel.invalidateAsync(); } }
setTargetsFiltered
6,074
boolean (@NotNull AnActionEvent e) { return myTarget.equals(AntConfigurationBase.getInstance(myProject).getTargetForEvent(myExecutionEvent)); }
isSelected
6,075
void (@NotNull AnActionEvent event, boolean state) { final AntConfigurationBase antConfiguration = AntConfigurationBase.getInstance(myProject); if (state) { final AntBuildFileBase buildFile = (AntBuildFileBase)((myTarget instanceof MetaTarget) ? ((MetaTarget)myTarget).getBuildFile() : myTarget.getModel().getBuildFile()...
setSelected
6,076
void (@NotNull AnActionEvent e) { super.update(e); final AntBuildFile buildFile = myTarget.getModel().getBuildFile(); e.getPresentation().setEnabled(buildFile != null && buildFile.exists()); }
update
6,077
ActionUpdateThread () { return ActionUpdateThread.BGT; }
getActionUpdateThread
6,078
void (@NotNull AnActionEvent e) { final AntExecuteBeforeRunDialog dialog = new AntExecuteBeforeRunDialog(myProject, myTarget); dialog.show(); }
actionPerformed
6,079
void (@NotNull AnActionEvent e) { e.getPresentation().setEnabled(myTarget.getModel().getBuildFile().exists()); }
update
6,080
ActionUpdateThread () { return ActionUpdateThread.BGT; }
getActionUpdateThread
6,081
void (@NotNull AnActionEvent e) { final AntBuildFile buildFile = getCurrentBuildFile(); if (buildFile != null) { final List<String> targets = getTargetNamesFromPaths(myTree.getSelectionPaths()); final ExecuteCompositeTargetEvent event = new ExecuteCompositeTargetEvent(targets); final SaveMetaTargetDialog dialog = new S...
actionPerformed
6,082
void (@NotNull AnActionEvent e) { final TreePath[] paths = myTree.getSelectionPaths(); e.getPresentation().setEnabled(paths != null && paths.length > 1 && canRunSelection()); }
update
6,083
ActionUpdateThread () { return ActionUpdateThread.EDT; }
getActionUpdateThread
6,084
void () { RemoveMetaTargetsOrBuildFileAction.this.unregisterCustomShortcutSet(myTree); }
dispose
6,085
void (ActionEvent e) { doAction(); }
actionPerformed
6,086
void (@NotNull AnActionEvent e) { doAction(); }
actionPerformed
6,087
void () { final TreePath[] paths = myTree.getSelectionPaths(); if (paths == null) { return; } try { // try to remove build file if (paths.length == 1) { final DefaultMutableTreeNode node = (DefaultMutableTreeNode)paths[0].getLastPathComponent(); if (node.getUserObject() instanceof AntBuildFileNodeDescriptor descriptor)...
doAction
6,088
void (@NotNull AnActionEvent e) { final Presentation presentation = e.getPresentation(); final TreePath[] paths = myTree.getSelectionPaths(); if (paths == null) { presentation.setEnabled(false); return; } if (paths.length == 1) { String text = AntBundle.message("remove.meta.target.action.name"); boolean enabled = false...
update
6,089
ActionUpdateThread () { return ActionUpdateThread.EDT; }
getActionUpdateThread
6,090
void (@NotNull AnActionEvent e) { new EditKeymapsDialog(myProject, myActionId).show(); }
actionPerformed
6,091
void (@NotNull AnActionEvent e) { e.getPresentation().setEnabled(myActionId != null && ActionManager.getInstance().getAction(myActionId) != null); }
update
6,092
ActionUpdateThread () { return ActionUpdateThread.BGT; }
getActionUpdateThread
6,093
boolean (final TransferSupport support) { if (canImport(support)) { addBuildFile(getAntFiles(support)); return true; } return false; }
importData
6,094
boolean (final TransferSupport support) { return FileCopyPasteUtil.isFileListFlavorAvailable(support.getDataFlavors()); }
canImport
6,095
VirtualFile[] (final TransferSupport support) { List<VirtualFile> virtualFileList = new ArrayList<>(); final List<File> fileList = FileCopyPasteUtil.getFileList(support.getTransferable()); if (fileList != null) { for (File file : fileList ) { ContainerUtil.addIfNotNull(virtualFileList, VfsUtil.findFileByIoFile(file, tr...
getAntFiles
6,096
void (@NotNull SimpleColoredComponent component) { component.append(toString(), SimpleTextAttributes.REGULAR_ATTRIBUTES); }
customize
6,097
Key<AntBeforeRunTask> () { return AntBeforeRunTaskProvider.ID; }
getTaskId
6,098
boolean (AntBeforeRunTask task) { return task.isRunningTarget(myTarget); }
isRunning
6,099
void (@NotNull AntBeforeRunTask task) { VirtualFile f = myTarget.getModel().getBuildFile().getVirtualFile(); task.setAntFileUrl(f != null ? f.getUrl() : null); task.setTargetName(f != null ? myTarget.getName() : null); }
update