本文整理汇总了Java中com.intellij.util.EventDispatcher.create方法的典型用法代码示例。如果您正苦于以下问题:Java EventDispatcher.create方法的具体用法?Java EventDispatcher.create怎么用?Java EventDispatcher.create使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.intellij.util.EventDispatcher
的用法示例。
在下文中一共展示了EventDispatcher.create方法的14个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: XBreakpointManagerImpl
import com.intellij.util.EventDispatcher; //导入方法依赖的package包/类
public XBreakpointManagerImpl(final Project project, final XDebuggerManagerImpl debuggerManager, StartupManager startupManager) {
myProject = project;
myDebuggerManager = debuggerManager;
myAllBreakpointsDispatcher = EventDispatcher.create(XBreakpointListener.class);
myDependentBreakpointManager = new XDependentBreakpointManager(this);
myLineBreakpointManager = new XLineBreakpointManager(project, myDependentBreakpointManager, startupManager);
if (!project.isDefault()) {
if (!ApplicationManager.getApplication().isUnitTestMode()) {
HttpVirtualFileListener httpVirtualFileListener = new HttpVirtualFileListener() {
@Override
public void fileDownloaded(@NotNull final VirtualFile file) {
updateBreakpointInFile(file);
}
};
HttpFileSystem.getInstance().addFileListener(httpVirtualFileListener, project);
}
for (XBreakpointType<?, ?> type : XBreakpointUtil.getBreakpointTypes()) {
addDefaultBreakpoint(type);
}
}
}
示例2: XDependentBreakpointManager
import com.intellij.util.EventDispatcher; //导入方法依赖的package包/类
public XDependentBreakpointManager(final XBreakpointManagerImpl breakpointManager) {
myBreakpointManager = breakpointManager;
myDispatcher = EventDispatcher.create(XDependentBreakpointListener.class);
myBreakpointManager.addBreakpointListener(new XBreakpointAdapter<XBreakpoint<?>>() {
public void breakpointRemoved(@NotNull final XBreakpoint<?> breakpoint) {
XDependentBreakpointInfo info = mySlave2Info.remove(breakpoint);
if (info != null) {
myMaster2Info.remove(info.myMasterBreakpoint, info);
}
Collection<XDependentBreakpointInfo> infos = myMaster2Info.removeAll((XBreakpointBase)breakpoint);
if (infos != null) {
for (XDependentBreakpointInfo breakpointInfo : infos) {
XDependentBreakpointInfo removed = mySlave2Info.remove(breakpointInfo.mySlaveBreakpoint);
if (removed != null) {
myDispatcher.getMulticaster().dependencyCleared(breakpointInfo.mySlaveBreakpoint);
}
}
}
}
});
}
示例3: XBreakpointManagerImpl
import com.intellij.util.EventDispatcher; //导入方法依赖的package包/类
public XBreakpointManagerImpl(final Project project, final XDebuggerManagerImpl debuggerManager, StartupManager startupManager) {
myProject = project;
myDebuggerManager = debuggerManager;
myAllBreakpointsDispatcher = EventDispatcher.create(XBreakpointListener.class);
myDependentBreakpointManager = new XDependentBreakpointManager(this);
myLineBreakpointManager = new XLineBreakpointManager(project, myDependentBreakpointManager, startupManager);
if (!project.isDefault() && !ApplicationManager.getApplication().isUnitTestMode()) {
HttpVirtualFileListener httpVirtualFileListener = new HttpVirtualFileListener() {
@Override
public void fileDownloaded(@NotNull final VirtualFile file) {
updateBreakpointInFile(file);
}
};
HttpFileSystem.getInstance().addFileListener(httpVirtualFileListener, project);
for (XBreakpointType<?, ?> type : XBreakpointUtil.getBreakpointTypes()) {
addDefaultBreakpoint(type);
}
}
}
示例4: XBreakpointManagerImpl
import com.intellij.util.EventDispatcher; //导入方法依赖的package包/类
public XBreakpointManagerImpl(final Project project, final XDebuggerManagerImpl debuggerManager, StartupManager startupManager) {
myProject = project;
myDebuggerManager = debuggerManager;
myAllBreakpointsDispatcher = EventDispatcher.create(XBreakpointListener.class);
myDependentBreakpointManager = new XDependentBreakpointManager(this);
myLineBreakpointManager = new XLineBreakpointManager(project, myDependentBreakpointManager, startupManager);
if (!project.isDefault()) {
if (!ApplicationManager.getApplication().isUnitTestMode()) {
HttpVirtualFileListener httpVirtualFileListener = this::updateBreakpointInFile;
HttpFileSystem.getInstance().addFileListener(httpVirtualFileListener, project);
}
for (XBreakpointType<?, ?> type : XBreakpointUtil.getBreakpointTypes()) {
addDefaultBreakpoint(type);
}
}
}
示例5: XDependentBreakpointManager
import com.intellij.util.EventDispatcher; //导入方法依赖的package包/类
public XDependentBreakpointManager(final XBreakpointManagerImpl breakpointManager) {
myBreakpointManager = breakpointManager;
myDispatcher = EventDispatcher.create(XDependentBreakpointListener.class);
myBreakpointManager.addBreakpointListener(new XBreakpointAdapter<XBreakpoint<?>>() {
public void breakpointRemoved(@Nonnull final XBreakpoint<?> breakpoint) {
XDependentBreakpointInfo info = mySlave2Info.remove(breakpoint);
if (info != null) {
myMaster2Info.remove(info.myMasterBreakpoint, info);
}
Collection<XDependentBreakpointInfo> infos = myMaster2Info.removeAll((XBreakpointBase)breakpoint);
if (infos != null) {
for (XDependentBreakpointInfo breakpointInfo : infos) {
XDependentBreakpointInfo removed = mySlave2Info.remove(breakpointInfo.mySlaveBreakpoint);
if (removed != null) {
myDispatcher.getMulticaster().dependencyCleared(breakpointInfo.mySlaveBreakpoint);
}
}
}
}
});
}
示例6: getPublisher
import com.intellij.util.EventDispatcher; //导入方法依赖的package包/类
@NotNull
@Override
public <T extends EventListener> T getPublisher(Class<T> listenerClass) {
EventDispatcher<?> dispatcher = myDispatchers.get(listenerClass);
if (dispatcher == null) {
dispatcher = EventDispatcher.create(listenerClass);
myDispatchers.put(listenerClass, dispatcher);
}
//noinspection unchecked
return (T)dispatcher.getMulticaster();
}
示例7: CheckboxTreeTable
import com.intellij.util.EventDispatcher; //导入方法依赖的package包/类
public CheckboxTreeTable(CheckedTreeNode root, CheckboxTree.CheckboxTreeCellRenderer renderer, final ColumnInfo[] columns) {
super(new ListTreeTableModelOnColumns(root, columns));
final TreeTableTree tree = getTree();
myEventDispatcher = EventDispatcher.create(CheckboxTreeListener.class);
CheckboxTreeHelper helper = new CheckboxTreeHelper(CheckboxTreeHelper.DEFAULT_POLICY, myEventDispatcher);
helper.initTree(tree, this, renderer);
tree.setSelectionRow(0);
}
示例8: getOrCreateDispatcher
import com.intellij.util.EventDispatcher; //导入方法依赖的package包/类
private <T extends XBreakpointProperties> EventDispatcher<XBreakpointListener> getOrCreateDispatcher(final XBreakpointType<?,T> type) {
EventDispatcher<XBreakpointListener> dispatcher = myDispatchers.get(type);
if (dispatcher == null) {
dispatcher = EventDispatcher.create(XBreakpointListener.class);
myDispatchers.put(type, dispatcher);
}
return dispatcher;
}
示例9: registerListener
import com.intellij.util.EventDispatcher; //导入方法依赖的package包/类
@Override
public <F extends Facet> void registerListener(@NotNull FacetTypeId<F> typeId, @NotNull ProjectWideFacetListener<? extends F> listener) {
EventDispatcher<ProjectWideFacetListener> dispatcher = myDispatchers.get(typeId);
if (dispatcher == null) {
dispatcher = EventDispatcher.create(ProjectWideFacetListener.class);
myDispatchers.put(typeId, dispatcher);
}
dispatcher.addListener(listener);
}
示例10: addListener
import com.intellij.util.EventDispatcher; //导入方法依赖的package包/类
@Override
public <F extends Facet> void addListener(final Class<F> facetClass, final FacetPointerListener<F> listener) {
EventDispatcher<FacetPointerListener> dispatcher = myDispatchers.get(facetClass);
if (dispatcher == null) {
dispatcher = EventDispatcher.create(FacetPointerListener.class);
myDispatchers.put(facetClass, dispatcher);
}
dispatcher.addListener(listener);
}
示例11: getOrCreateDispatcher
import com.intellij.util.EventDispatcher; //导入方法依赖的package包/类
private <T extends XBreakpointProperties> EventDispatcher<XBreakpointListener> getOrCreateDispatcher(final XBreakpointType<?, T> type) {
EventDispatcher<XBreakpointListener> dispatcher = myDispatchers.get(type);
if (dispatcher == null) {
dispatcher = EventDispatcher.create(XBreakpointListener.class);
myDispatchers.put(type, dispatcher);
}
return dispatcher;
}
示例12: ensureListenerCreated
import com.intellij.util.EventDispatcher; //导入方法依赖的package包/类
private void ensureListenerCreated() {
if (myListener == null) {
myListener = EventDispatcher.create(SvnAuthenticationListener.class);
}
}
示例13: FossilLineCommand
import com.intellij.util.EventDispatcher; //导入方法依赖的package包/类
public FossilLineCommand(Project project, File workingDirectory, @NotNull FCommandName commandName) {
super(project, workingDirectory, commandName);
myLineListeners = EventDispatcher.create(LineProcessEventListener.class);
}
示例14: SvnLineCommand
import com.intellij.util.EventDispatcher; //导入方法依赖的package包/类
public SvnLineCommand(File workingDirectory, @NotNull SvnCommandName commandName, @NotNull @NonNls String exePath, File configDir) {
super(workingDirectory, commandName, exePath, configDir);
myLineListeners = EventDispatcher.create(LineProcessEventListener.class);
myExitCode = new AtomicReference<Integer>();
myErr = new StringBuffer();
}