Unnamed: 0 int64 0 305k | body stringlengths 7 52.9k | name stringlengths 1 185 |
|---|---|---|
258,700 | void () { if (myAddedFiles.isEmpty() || myMovedFiles.isEmpty()) return; Map<String, VirtualFile> addedPaths = new HashMap<>(myAddedFiles.size()); for (VirtualFile file : myAddedFiles) { addedPaths.put(file.getPath(), file); } for (Iterator<MovedFileInfo> iterator = myMovedFiles.iterator(); iterator.hasNext(); ) { Moved... | checkMovedAddedSourceBack |
258,701 | void () { if (myDeletedFiles.isEmpty()) return; Set<String> copiedAddedMoved = new HashSet<>(); for (VirtualFile file : myCopyFromMap.keySet()) { copiedAddedMoved.add(file.getPath()); } for (VirtualFile file : myAddedFiles) { copiedAddedMoved.add(file.getPath()); } for (MovedFileInfo movedFileInfo : myMovedFiles) { cop... | doNotDeleteAddedCopiedOrMovedFiles |
258,702 | boolean () { return withLock(PROCESSING_LOCK.readLock(), () -> !myAddedFiles.isEmpty() || !myDeletedFiles.isEmpty() || !myMovedFiles.isEmpty()); } | isAnythingToProcess |
258,703 | void () { withLock(PROCESSING_LOCK.writeLock(), () -> { doNotDeleteAddedCopiedOrMovedFiles(); checkMovedAddedSourceBack(); }); executeAdd(); executeDelete(); executeMoveRename(); } | executePendingTasks |
258,704 | void (@NotNull VFileCreateEvent event) { if (LOG.isDebugEnabled()) LOG.debug("fileCreated: ", event.getFile()); if (!event.isDirectory()) { VirtualFile file = event.getFile(); if (file == null) return; LOG.debug("Adding [", file, "] to added files"); withLock(PROCESSING_LOCK.writeLock(), () -> { myAddedFiles.add(file);... | processFileCreated |
258,705 | void (@NotNull VFileMoveEvent event) { VirtualFile file = event.getFile(); VirtualFile oldParent = event.getOldParent(); if (!isUnderMyVcs(oldParent)) { withLock(PROCESSING_LOCK.writeLock(), () -> { myAddedFiles.add(file); }); } } | processFileMoved |
258,706 | void (@NotNull VFileCopyEvent event) { VirtualFile newFile = event.getNewParent().findChild(event.getNewChildName()); if (newFile == null || myChangeListManager.isIgnoredFile(newFile)) return; VirtualFile originalFile = event.getFile(); if (isFileCopyingFromTrackingSupported() && isUnderMyVcs(originalFile)) { withLock(... | processFileCopied |
258,707 | void (@NotNull VFileDeleteEvent event) { processBeforeDeletedFile(event.getFile()); } | processBeforeDeletedFile |
258,708 | void (@NotNull VirtualFile file) { if (file.isDirectory() && file instanceof NewVirtualFile && !isRecursiveDeleteSupported()) { for (VirtualFile child : ((NewVirtualFile)file).getCachedChildren()) { ProgressManager.checkCanceled(); FileStatus status = myChangeListManager.getStatus(child); if (!filterOutByStatus(status)... | processBeforeDeletedFile |
258,709 | void (@NotNull VirtualFile file, @NotNull String newParentPath, @NotNull String newName) { FileStatus status = myChangeListManager.getStatus(file); LOG.debug("Checking moved file ", file, "; status=", status); String newPath = newParentPath + "/" + newName; withLock(PROCESSING_LOCK.writeLock(), () -> { if (!filterOutBy... | processMovedFile |
258,710 | void (@NotNull VFileMoveEvent event) { VirtualFile file = event.getFile(); if (isUnderMyVcs(event.getNewParent())) { LOG.debug("beforeFileMovement ", event, " into same vcs"); addFileToMove(file, event.getNewParent().getPath(), file.getName()); } else { LOG.debug("beforeFileMovement ", event, " into different vcs"); my... | processBeforeFileMovement |
258,711 | void (@NotNull VFilePropertyChangeEvent event) { if (event.isRename()) { LOG.debug("before file rename ", event); String newName = (String)event.getNewValue(); VirtualFile file = event.getFile(); VirtualFile parent = file.getParent(); if (parent != null) { addFileToMove(file, parent.getPath(), newName); } } } | processBeforePropertyChange |
258,712 | void (@NotNull VirtualFile file, @NotNull String newParentPath, @NotNull String newName) { if (file.isDirectory() && !file.is(VFileProperty.SYMLINK)) { @SuppressWarnings("UnsafeVfsRecursion") VirtualFile[] children = file.getChildren(); if (children != null) { for (VirtualFile child : children) { ProgressManager.checkC... | addFileToMove |
258,713 | void (@NotNull List<? extends VFileEvent> events) { for (VFileEvent event : events) { if (isEventIgnored(event)) continue; if (event instanceof VFileDeleteEvent && allowedDeletion(event)) { processBeforeDeletedFile((VFileDeleteEvent)event); } else if (event instanceof VFileMoveEvent) { processBeforeFileMovement((VFileM... | processBeforeEvents |
258,714 | void (@NotNull List<? extends VFileEvent> events) { for (VFileEvent event : events) { ProgressManager.checkCanceled(); if (isEventIgnored(event)) continue; if (event instanceof VFileCreateEvent) { processFileCreated((VFileCreateEvent)event); } else if (event instanceof VFileCopyEvent) { processFileCopied((VFileCopyEven... | processAfterEvents |
258,715 | void () { VirtualFileManager.getInstance().addAsyncFileListener(new MyAsyncVfsListener(), this); myProject.getMessageBus().connect(this).subscribe(CommandListener.TOPIC, new MyCommandAdapter()); myProjectConfigurationFilesProcessor.install(); myExternalFilesProcessor.install(); myIgnoreFilesProcessor.install(); } | installListeners |
258,716 | void () { } | dispose |
258,717 | boolean (@NotNull VFileEvent event) { return !event.isFromRefresh() && (event.getFileSystem() instanceof LocalFileSystem); } | isEventAccepted |
258,718 | boolean (@NotNull VFileEvent event) { FilePath filePath = getEventFilePath(event); return !isUnderMyVcs(filePath) || myChangeListManager.isIgnoredFile(filePath); } | isEventIgnored |
258,719 | boolean (@Nullable VirtualFile file) { return file != null && ReadAction.compute(() -> !myProject.isDisposed() && myVcsManager.getVcsFor(file) == myVcs); } | isUnderMyVcs |
258,720 | boolean (@Nullable FilePath filePath) { return filePath != null && ReadAction.compute(() -> !myProject.isDisposed() && myVcsManager.getVcsFor(filePath) == myVcs); } | isUnderMyVcs |
258,721 | FilePath (@NotNull VFileEvent event) { if (event instanceof VFileCreateEvent createEvent) { return VcsUtil.getFilePath(event.getPath(), createEvent.isDirectory()); } VirtualFile file = event.getFile(); if (file != null) { // Do not use file.getPath(), as it is slower. return VcsUtil.getFilePath(event.getPath(), file.is... | getEventFilePath |
258,722 | boolean (@NotNull VFileEvent event) { if (myVcsFileListenerContextHelper.isDeletionContextEmpty()) return true; return !myVcsFileListenerContextHelper.isDeletionIgnored(getEventFilePath(event)); } | allowedDeletion |
258,723 | boolean (@NotNull VFileEvent event) { if (myVcsFileListenerContextHelper.isAdditionContextEmpty()) return true; return !myVcsFileListenerContextHelper.isAdditionIgnored(getEventFilePath(event)); } | allowedAddition |
258,724 | void () { List<VirtualFile> addedFiles = myProcessor.acquireAddedFiles(); Map<VirtualFile, VirtualFile> copyFromMap = myProcessor.acquireCopiedFiles(); LOG.debug("executeAdd. addedFiles: ", addedFiles); VcsShowConfirmationOption.Value addOption = myAddOption.getValue(); if (addOption == VcsShowConfirmationOption.Value.... | executeAdd |
258,725 | void (@NotNull List<VirtualFile> addedFiles, @NotNull Map<VirtualFile, VirtualFile> copyFromMap) { if (ApplicationManager.getApplication().isDispatchThread()) { // backward compatibility with plugins ApplicationManager.getApplication().executeOnPooledThread(() -> { performAddingWithConfirmation(addedFiles, copyFromMap)... | executeAdd |
258,726 | void (@NotNull List<VirtualFile> addedFiles, @NotNull Map<VirtualFile, VirtualFile> copyFromMap) { VcsShowConfirmationOption.Value addOption = myAddOption.getValue(); LOG.debug("executeAdd. add-option: ", addOption, ", files to add: ", addedFiles); if (addOption == VcsShowConfirmationOption.Value.DO_NOTHING_SILENTLY) r... | performAddingWithConfirmation |
258,727 | void () { List<MovedFileInfo> movedFiles = myProcessor.acquireMovedFiles(); LOG.debug("executeMoveRename ", movedFiles); if (movedFiles.isEmpty()) return; performMoveRename(movedFiles); } | executeMoveRename |
258,728 | void () { List<FilePath> deletedFiles = myProcessor.acquireDeletedFiles(); LOG.debug("executeDelete ", deletedFiles); VcsShowConfirmationOption.Value removeOption = myRemoveOption.getValue(); if (removeOption == VcsShowConfirmationOption.Value.DO_NOTHING_SILENTLY) return; deletedFiles.removeIf(myVcsIgnoreManager::isPot... | executeDelete |
258,729 | void () { FileDocumentManager fileDocumentManager = FileDocumentManager.getInstance(); Set<String> ignoreFileNames = VcsUtil.getVcsIgnoreFileNames(myProject); for (Document document : fileDocumentManager.getUnsavedDocuments()) { VirtualFile file = fileDocumentManager.getFile(document); if (file != null && ignoreFileNam... | saveUnsavedVcsIgnoreFiles |
258,730 | List<FilePath> (@NotNull List<FilePath> deletedFiles) { return selectFilePathsForOption(myRemoveOption, deletedFiles, getDeleteTitle(), getSingleFileDeleteTitle(), getSingleFileDeletePromptTemplate(), CommonBundle.message("button.delete"), CommonBundle.getCancelButtonText()); } | selectFilePathsToDelete |
258,731 | List<FilePath> (@NotNull List<FilePath> addFiles) { return selectFilePathsForOption(myAddOption, addFiles, getAddTitle(), getSingleFileAddTitle(), getSingleFileAddPromptTemplate(), CommonBundle.getAddButtonText(), CommonBundle.getCancelButtonText()); } | selectFilePathsToAdd |
258,732 | List<VirtualFile> (@NotNull List<VirtualFile> addFiles) { return selectFilesForOption(myAddOption, addFiles, getAddTitle(), getSingleFileAddTitle(), getSingleFileAddPromptTemplate()); } | selectFilesToAdd |
258,733 | List<FilePath> (@NotNull VcsShowConfirmationOption option, @NotNull List<FilePath> files, @NlsContexts.DialogTitle String title, @NlsContexts.DialogTitle String singleFileTitle, @NlsContexts.DialogMessage String singleFilePromptTemplate, @NlsActions.ActionText @Nullable String okActionName, @NlsActions.ActionText @Null... | selectFilePathsForOption |
258,734 | List<VirtualFile> (@NotNull VcsShowConfirmationOption option, @NotNull List<VirtualFile> files, @NlsContexts.DialogTitle String title, @NlsContexts.DialogTitle String singleFileTitle, @NlsContexts.DialogMessage String singleFilePromptTemplate) { VcsShowConfirmationOption.Value optionValue = option.getValue(); if (optio... | selectFilesForOption |
258,735 | boolean () { return false; } | processBeforeContentsChange |
258,736 | void (@NotNull List<VFileContentChangeEvent> events) { } | beforeContentsChange |
258,737 | void (@NotNull VirtualFile file, @NotNull String newParentPath, @NotNull String newName) { } | processMovedFile |
258,738 | boolean (@NotNull FileStatus status) { return status == FileStatus.IGNORED || status == FileStatus.UNKNOWN; } | filterOutByStatus |
258,739 | boolean (@NotNull FileStatus status) { return false; } | shouldIgnoreDeletion |
258,740 | boolean () { return false; } | isRecursiveDeleteSupported |
258,741 | boolean () { return true; } | isFileCopyingFromTrackingSupported |
258,742 | ExternallyAddedFilesProcessorImpl () { return new ExternallyAddedFilesProcessorImpl(myProject, this, myVcs, (files) -> { performAdding((Collection<VirtualFile>)files, emptyMap()); return Unit.INSTANCE; }); } | createExternalFilesProcessor |
258,743 | ProjectConfigurationFilesProcessorImpl () { return new ProjectConfigurationFilesProcessorImpl(myProject, this, myVcs, (files) -> { performAdding((Collection<VirtualFile>)files, emptyMap()); return Unit.INSTANCE; }); } | createProjectConfigurationFilesProcessor |
258,744 | IgnoreFilesProcessorImpl () { return new IgnoreFilesProcessorImpl(myProject, this, myVcs); } | createIgnoreFilesProcessor |
258,745 | boolean (@NotNull VFileEvent event) { return event instanceof VFileDeleteEvent || event instanceof VFileMoveEvent || event instanceof VFilePropertyChangeEvent; } | isBeforeEvent |
258,746 | boolean (@NotNull VFileEvent event) { return event instanceof VFileCreateEvent || event instanceof VFileCopyEvent || event instanceof VFileMoveEvent; } | isAfterEvent |
258,747 | ChangeApplier (@NotNull List<? extends @NotNull VFileEvent> events) { List<VFileContentChangeEvent> contentChangedEvents = new ArrayList<>(); List<VFileEvent> beforeEvents = new ArrayList<>(); List<VFileEvent> afterEvents = new ArrayList<>(); for (VFileEvent event : events) { ProgressManager.checkCanceled(); if (event ... | prepareChange |
258,748 | void () { beforeContentsChange(contentChangedEvents); myProcessor.processBeforeEvents(beforeEvents); } | beforeVfsChange |
258,749 | void () { myEventsToProcess.addAll(afterEvents); } | afterVfsChange |
258,750 | void (@NotNull CommandEvent event) { if (myProject != event.getProject()) return; /* * Create file events cannot be filtered in afterVfsChange since VcsFileListenerContextHelper populated after actual file creation in PathsVerifier.CheckAdded.check * So this commandFinished is the only way to get in sync with VcsFileLi... | commandFinished |
258,751 | void (List<? extends VFileEvent> events) { new Task.Backgroundable(myProject, VcsBundle.message("progress.title.version.control.processing.changed.files"), true) { @Override public void run(@NotNull ProgressIndicator indicator) { try { indicator.checkCanceled(); myProcessor.processAfterEvents(events); myProcessor.execu... | processEventsInBackground |
258,752 | void (@NotNull ProgressIndicator indicator) { try { indicator.checkCanceled(); myProcessor.processAfterEvents(events); myProcessor.executePendingTasks(); } catch (ProcessCanceledException e) { myProcessor.clearAllPendingTasks(); } } | run |
258,753 | boolean (Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; FilePathImpl path = (FilePathImpl)o; if (myIsDirectory != path.myIsDirectory) return false; if (!(SystemInfoRt.isFileSystemCaseSensitive ? myPath.equals(path.myPath) : myPath.equalsIgnoreCase(path.myPath))) { ret... | equals |
258,754 | int () { int result = SystemInfoRt.isFileSystemCaseSensitive ? myPath.hashCode() : Strings.stringHashCodeInsensitive(myPath); result = 31 * result + (myIsDirectory ? 1 : 0); return result; } | hashCode |
258,755 | void () { } | refresh |
258,756 | void () { LocalFileSystem.getInstance().refreshAndFindFileByPath(myPath); } | hardRefresh |
258,757 | String () { return myPath; } | getPath |
258,758 | boolean () { return myIsDirectory; } | isDirectory |
258,759 | boolean (@NotNull FilePath parent, boolean strict) { return FileUtil.isAncestor(parent.getPath(), getPath(), strict); } | isUnder |
258,760 | FilePath () { String parent = PathUtil.getParentPath(myPath); return parent.isEmpty() ? null : new FilePathImpl(parent, true); } | getParentPath |
258,761 | VirtualFile () { return LocalFileSystem.getInstance().findFileByPath(myPath); } | getVirtualFile |
258,762 | VirtualFile () { FilePath parent = getParentPath(); return parent != null ? parent.getVirtualFile() : null; } | getVirtualFileParent |
258,763 | File () { return new File(myPath); } | getIOFile |
258,764 | String () { return PathUtil.getFileName(myPath); } | getName |
258,765 | String () { return FileUtil.toSystemDependentName(myPath); } | getPresentableUrl |
258,766 | Document () { VirtualFile file = getVirtualFile(); if (file == null || file.getFileType().isBinary()) { return null; } return FileDocumentManager.getInstance().getDocument(file); } | getDocument |
258,767 | Charset () { return getCharset(null); } | getCharset |
258,768 | Charset (@Nullable Project project) { VirtualFile file = getVirtualFile(); String path = myPath; while ((file == null || !file.isValid()) && !path.isEmpty()) { path = PathUtil.getParentPath(path); file = LocalFileSystem.getInstance().findFileByPath(path); } if (file != null) { return file.getCharset(); } EncodingManage... | getCharset |
258,769 | FileType () { VirtualFile file = getVirtualFile(); FileTypeManager manager = FileTypeManager.getInstance(); return file != null ? manager.getFileTypeByFile(file) : manager.getFileTypeByFileName(getName()); } | getFileType |
258,770 | String () { return myPath + (myIsDirectory ? "/" : ""); } | toString |
258,771 | boolean () { return false; } | isNonLocal |
258,772 | boolean (@NotNull Attribute attribute) { final Element parent = attribute.getParent(); final String parentName = parent.getName(); if ("MESSAGE".equals(parentName) && Constants.VALUE.equals(attribute.getName())) { return true; } if (Constants.OPTION.equals(parentName) && "LAST_COMMIT_MESSAGE".equals(parent.getAttribute... | skipPathMacros |
258,773 | Value () { return myValue; } | getValue |
258,774 | void (Value value) { myValue = value; } | setValue |
258,775 | boolean () { return true; } | isPersistent |
258,776 | String () { return "vcs"; } | getId |
258,777 | void (@NotNull final List<? extends Pair<String, String>> entries, @NotNull final Context context, @NotNull final Runnable runNext) { if (!getDirectory(context)) return; if (!getDirectoryName(context)) return; ProgressManager.getInstance().run(new Task.Backgroundable(null, VcsBundle.message("progress.title.hey"), true)... | processEntries |
258,778 | void (@NotNull ProgressIndicator indicator) { for (Pair<String, String> pair : entries) { String vcs = pair.getFirst(); final VcsCheckoutProcessor processor = VcsCheckoutProcessor.getProcessor(vcs); if (processor == null) { LOG.error("Checkout processor not found for " + vcs); return; } JsonElement element = new JsonPa... | run |
258,779 | boolean (@NotNull Context context) { if (ApplicationManager.getApplication().isUnitTestMode()) { context.directoryName = "test"; return true; } context.directoryName = Messages.showInputDialog((Project)null, VcsBundle.message("dialog.message.enter.directory.name", context.directory.getName()), VcsBundle.message("dialog... | getDirectoryName |
258,780 | boolean (@NotNull Context context) { if (context.directory != null) return true; FileChooserDescriptor descriptor = new FileChooserDescriptor(false, true, false, false, false, false); descriptor.setTitle(VcsBundle.message("dialog.title.select.destination.folder")); descriptor.setDescription(""); VirtualFile[] files = F... | getDirectory |
258,781 | VcsNotifier (@NotNull Project project) { return project.getService(VcsNotifier.class); } | getInstance |
258,782 | Notification (@NotNull Notification notification) { notification.notify(myProject); return notification; } | notify |
258,783 | Notification (@NotificationTitle @NotNull String title, @NotificationContent @NotNull String message) { return notifyError(null, title, message, (NotificationListener)null); } | notifyError |
258,784 | Notification (@NonNls @Nullable String displayId, @NotificationTitle @NotNull String title, @NotificationContent @NotNull String message) { return notifyError(displayId, title, message, (NotificationListener)null); } | notifyError |
258,785 | Notification (@NonNls @Nullable String displayId, @NotificationTitle @NotNull String title, @NotificationContent @NotNull String message, boolean showDetailsAction) { Notification notification = createNotification(IMPORTANT_ERROR_NOTIFICATION, displayId, title, message, NotificationType.ERROR, null); if (showDetailsAct... | notifyError |
258,786 | Notification (@NotificationTitle @NotNull String title, @NotificationContent @NotNull String message, @Nullable NotificationListener listener) { return notify(IMPORTANT_ERROR_NOTIFICATION, null, title, message, NotificationType.ERROR, listener); } | notifyError |
258,787 | Notification (@NonNls @Nullable String displayId, @NotificationTitle @NotNull String title, @NotificationContent @NotNull String message, @Nullable NotificationListener listener) { return notify(IMPORTANT_ERROR_NOTIFICATION, displayId, title, message, NotificationType.ERROR, listener); } | notifyError |
258,788 | Notification (@NonNls @Nullable String displayId, @NotificationTitle @NotNull String title, @NotificationContent @NotNull String message, NotificationAction... actions) { return notify(IMPORTANT_ERROR_NOTIFICATION, displayId, title, message, NotificationType.ERROR, actions); } | notifyError |
258,789 | Notification (@NonNls @Nullable String displayId, @NotificationTitle @NotNull String title, @NotificationContent @NotNull String message, @Nullable Collection<? extends Exception> errors) { return notifyError(displayId, title, buildNotificationMessage(message, errors)); } | notifyError |
258,790 | Notification (@NonNls @Nullable String displayId, @NotificationContent @NotNull String message) { return notify(NOTIFICATION_GROUP_ID, displayId, "", message, NotificationType.ERROR); } | notifyWeakError |
258,791 | Notification (@NonNls @Nullable String displayId, @NotificationTitle @NotNull String title, @NotificationContent @NotNull String message) { return notify(NOTIFICATION_GROUP_ID, displayId, title, message, NotificationType.ERROR); } | notifyWeakError |
258,792 | Notification (@NotificationContent @NotNull String message) { return notify(NOTIFICATION_GROUP_ID, null, "", message, NotificationType.INFORMATION); } | notifySuccess |
258,793 | Notification (@NotificationTitle @NotNull String title, @NotificationContent @NotNull String message) { return notify(NOTIFICATION_GROUP_ID, null, title, message, NotificationType.INFORMATION); } | notifySuccess |
258,794 | Notification (@NonNls @Nullable String displayId, @NotificationTitle @NotNull String title, @NotificationContent @NotNull String message) { return notify(NOTIFICATION_GROUP_ID, displayId, title, message, NotificationType.INFORMATION); } | notifySuccess |
258,795 | Notification (@NotificationTitle @NotNull String title, @NotificationContent @NotNull String message, @Nullable NotificationListener listener) { return notify(NOTIFICATION_GROUP_ID, null, title, message, NotificationType.INFORMATION, listener); } | notifySuccess |
258,796 | Notification (@NonNls @Nullable String displayId, @NotificationTitle @NotNull String title, @NotificationContent @NotNull String message, @Nullable NotificationListener listener) { return notify(NOTIFICATION_GROUP_ID, displayId, title, message, NotificationType.INFORMATION, listener); } | notifySuccess |
258,797 | Notification (@NotificationTitle @NotNull String title, @NotificationContent @NotNull String message, @Nullable NotificationListener listener) { return notify(IMPORTANT_ERROR_NOTIFICATION, null, title, message, NotificationType.INFORMATION, listener); } | notifyImportantInfo |
258,798 | Notification (@NonNls @Nullable String displayId, @NotificationTitle @NotNull String title, @NotificationContent @NotNull String message, @Nullable NotificationListener listener) { return notify(IMPORTANT_ERROR_NOTIFICATION, displayId, title, message, NotificationType.INFORMATION, listener); } | notifyImportantInfo |
258,799 | Notification (@NonNls @Nullable String displayId, @NotificationTitle @NotNull String title, @NotificationContent @NotNull String message) { return notify(IMPORTANT_ERROR_NOTIFICATION, displayId, title, message, NotificationType.INFORMATION); } | notifyImportantInfo |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.