Java 类com.intellij.openapi.vfs.impl.BulkVirtualFileListenerAdapter 实例源码

项目:intellij-ce-playground    文件:DeprecatedVirtualFileSystem.java   
protected void startEventPropagation() {
  Application application = ApplicationManager.getApplication();
  if (application == null) {
    return;
  }

  application.getMessageBus().connect().subscribe(
    VirtualFileManager.VFS_CHANGES, new BulkVirtualFileListenerAdapter(myEventDispatcher.getMulticaster(), this));
}
项目:intellij-ce-playground    文件:FileBasedIndexImpl.java   
@Override
public void after(@NotNull List<? extends VFileEvent> events) {
  myContentlessIndicesUpdateQueue.ensureUpToDate();

  for (VFileEvent event : events) {
    BulkVirtualFileListenerAdapter.fireAfter(this, event);
  }
  myContentlessIndicesUpdateQueue.signalUpdateEnd();
}
项目:tools-idea    文件:DeprecatedVirtualFileSystem.java   
protected void startEventPropagation() {
  Application application = ApplicationManager.getApplication();
  if (application == null) {
    return;
  }

  application.getMessageBus().connect().subscribe(
    VirtualFileManager.VFS_CHANGES, new BulkVirtualFileListenerAdapter(myEventDispatcher.getMulticaster(), this));
}
项目:tools-idea    文件:DirectoryIndexImpl.java   
@Override
public void after(@NotNull List<? extends VFileEvent> events) {
  if (myBatchChangePlanned) {
    myBatchChangePlanned = false;
    long started = System.currentTimeMillis();
    doInitialize();
    LOG.info("Rebuilt indexstate for " + (System.currentTimeMillis() - started));
  }
  else {
    for (VFileEvent event : events) {
      BulkVirtualFileListenerAdapter.fireAfter(this, event);
    }
  }
}
项目:tools-idea    文件:PsiVFSListener.java   
public PsiVFSListener(StartupManager startupManager,
                      FileTypeManager fileTypeManager,
                      PsiManager psiManager, 
                      ProjectRootManager projectRootManager) {
  myFileTypeManager = fileTypeManager;
  myProjectRootManager = projectRootManager;
  myProjectFileIndex = myProjectRootManager.getFileIndex();
  myManager = (PsiManagerImpl) psiManager;
  myFileManager = (FileManagerImpl) myManager.getFileManager();

  myConnection = psiManager.getProject().getMessageBus().connect(psiManager.getProject());

  startupManager.registerPreStartupActivity(new Runnable() {
    @Override
    public void run() {
      myConnection.subscribe(VirtualFileManager.VFS_CHANGES, new BulkVirtualFileListenerAdapter(PsiVFSListener.this));
      myConnection.subscribe(ProjectTopics.PROJECT_ROOTS, new MyModuleRootListener());
      myConnection.subscribe(FileTypeManager.TOPIC, new FileTypeListener.Adapter() {
        @Override
        public void fileTypesChanged(FileTypeEvent e) {
          myFileManager.processFileTypesChanged();
        }
      });
      myConnection.subscribe(AppTopics.FILE_DOCUMENT_SYNC, new MyFileDocumentManagerAdapter());
      myFileManager.markInitialized();
    }
  });
}
项目:tools-idea    文件:FileBasedIndexImpl.java   
@Override
public void after(@NotNull List<? extends VFileEvent> events) {
  myContentlessIndicesUpdateQueue.ensureUpToDate();

  for (VFileEvent event : events) {
    BulkVirtualFileListenerAdapter.fireAfter(this, event);
  }
  myContentlessIndicesUpdateQueue.signalUpdateEnd();
}
项目:consulo    文件:LocalHistoryEventDispatcher.java   
@Override
public void before(@Nonnull List<? extends VFileEvent> events) {
  myGateway.runWithVfsEventsDispatchContext(events, true, () -> {
    for (VFileEvent event : events) {
      BulkVirtualFileListenerAdapter.fireBefore(myVfsEventsDispatcher.getMulticaster(), event);
    }
  });
}
项目:consulo    文件:LocalHistoryEventDispatcher.java   
@Override
public void after(@Nonnull List<? extends VFileEvent> events) {
  myGateway.runWithVfsEventsDispatchContext(events, false, () -> {
    for (VFileEvent event : events) {
      BulkVirtualFileListenerAdapter.fireAfter(myVfsEventsDispatcher.getMulticaster(), event);
    }
  });
}
项目:consulo    文件:DeprecatedVirtualFileSystem.java   
protected void startEventPropagation() {
  Application application = ApplicationManager.getApplication();
  if (application == null) {
    return;
  }

  application.getMessageBus().connect().subscribe(
          VirtualFileManager.VFS_CHANGES, new BulkVirtualFileListenerAdapter(myEventDispatcher.getMulticaster(), this));
}
项目:consulo    文件:ContentEntryFileListener.java   
public ContentEntryFileListener(Application application, ProjectManager projectManager) {
  application.getMessageBus().connect().subscribe(VirtualFileManager.VFS_CHANGES, new BulkFileListener() {
    @Override
    public void before(@Nonnull List<? extends VFileEvent> events) {
      for (Project project : projectManager.getOpenProjects()) {
        new BulkVirtualFileListenerAdapter(new Listener(project), LocalFileSystem.getInstance()).before(events);
      }
    }
  });
}
项目:consulo    文件:PsiVFSListener.java   
@Override
public void before(@Nonnull List<? extends VFileEvent> events) {
  for (VFileEvent event : events) {
    BulkVirtualFileListenerAdapter.fireBefore(this, event);
  }
}
项目:consulo    文件:PsiVFSListener.java   
@Override
public void after(@Nonnull List<? extends VFileEvent> events) {
  for (VFileEvent event : events) {
    BulkVirtualFileListenerAdapter.fireAfter(this, event);
  }
}
项目:consulo    文件:IndexedFilesListener.java   
@Override
public void before(@Nonnull List<? extends VFileEvent> events) {
  for (VFileEvent event : events) {
    BulkVirtualFileListenerAdapter.fireBefore(this, event);
  }
}
项目:consulo    文件:IndexedFilesListener.java   
@Override
public void after(@Nonnull List<? extends VFileEvent> events) {
  for (VFileEvent event : events) {
    BulkVirtualFileListenerAdapter.fireAfter(this, event);
  }
}