当前位置: 首页>>代码示例>>Java>>正文


Java Comparing.haveEqualElements方法代码示例

本文整理汇总了Java中com.intellij.openapi.util.Comparing.haveEqualElements方法的典型用法代码示例。如果您正苦于以下问题:Java Comparing.haveEqualElements方法的具体用法?Java Comparing.haveEqualElements怎么用?Java Comparing.haveEqualElements使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在com.intellij.openapi.util.Comparing的用法示例。


在下文中一共展示了Comparing.haveEqualElements方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: checkIfProjectLogMatches

import com.intellij.openapi.util.Comparing; //导入方法依赖的package包/类
private static boolean checkIfProjectLogMatches(@NotNull Project project,
                                                @NotNull GitVcs vcs,
                                                @NotNull ContentManager cm,
                                                @NotNull List<VirtualFile> requestedRoots) {
  VirtualFile[] projectRoots = ProjectLevelVcsManager.getInstance(project).getRootsUnderVcs(vcs);
  if (Comparing.haveEqualElements(requestedRoots, Arrays.asList(projectRoots))) {
    Content[] contents = cm.getContents();
    for (Content content : contents) {
      if (VcsLogContentProvider.TAB_NAME.equals(content.getDisplayName())) {
        cm.setSelectedContent(content);
        return true;
      }
    }
  }
  return false;
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:17,代码来源:GitShowExternalLogAction.java

示例2: add

import com.intellij.openapi.util.Comparing; //导入方法依赖的package包/类
public boolean add(ThreadState state) {
  if (myOriginalState.isEDT()) return false;
  if (!Comparing.equal(state.myState, myOriginalState.myState)) return false;
  if (state.myEmptyStackTrace != myOriginalState.myEmptyStackTrace) return false;
  if (state.isDaemon != myOriginalState.isDaemon) return false;
  if (!Comparing.equal(state.myJavaThreadState, myOriginalState.myJavaThreadState)) return false;
  if (!Comparing.equal(state.myThreadStateDetail, myOriginalState.myThreadStateDetail)) return false;
  if (!Comparing.equal(state.myExtraState, myOriginalState.myExtraState)) return false;
  if (!Comparing.haveEqualElements(state.myThreadsWaitingForMyLock, myOriginalState.myThreadsWaitingForMyLock)) return false;
  if (!Comparing.haveEqualElements(state.myDeadlockedThreads, myOriginalState.myDeadlockedThreads)) return false;
  if (!Comparing.equal(getMergeableStackTrace(state.myStackTrace, true), getMergeableStackTrace(myOriginalState.myStackTrace, true))) return false;
  myCounter++;
  return true;
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:15,代码来源:ThreadState.java

示例3: MultipleChangeListBrowser

import com.intellij.openapi.util.Comparing; //导入方法依赖的package包/类
public MultipleChangeListBrowser(final Project project, final List<? extends ChangeList> changeLists, final List<Change> changes,
                                 Disposable parentDisposable,
                                 final ChangeList initialListSelection,
                                 final boolean capableOfExcludingChanges,
                                 final boolean highlightProblems, final Runnable rebuildListListener, @Nullable final Runnable inclusionListener,
                                 final AnAction... additionalActions) {
  super(project, changeLists, changes, initialListSelection, capableOfExcludingChanges, highlightProblems, inclusionListener, MyUseCase.LOCAL_CHANGES, null);
  myParentDisposable = parentDisposable;
  myRebuildListListener = rebuildListListener;

  myChangeListChooser = new ChangeListChooser(changeLists);
  myHeaderPanel.add(myChangeListChooser, BorderLayout.EAST);
  myShowingAllChangeLists = Comparing.haveEqualElements((List<LocalChangeList>) changeLists, ChangeListManager.getInstance(project).getChangeLists());
  ChangeListManager.getInstance(myProject).addChangeListListener(myChangeListListener);

  myExtender = new Extender(project, this, additionalActions);

  ActionManager actionManager = ActionManager.getInstance();
  final AnAction moveAction = actionManager.getAction(IdeActions.MOVE_TO_ANOTHER_CHANGE_LIST);
  actionManager.addAnActionListener(new AnActionListener.Adapter() {
    @Override
    public void afterActionPerformed(AnAction action, DataContext dataContext, AnActionEvent event) {
      if (moveAction.equals(action)) {
        rebuildList();
      }
    }
  }, myParentDisposable);

}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:30,代码来源:MultipleChangeListBrowser.java

示例4: equals

import com.intellij.openapi.util.Comparing; //导入方法依赖的package包/类
@Override
public boolean equals(Object o) {
  if (this == o) return true;
  if (!(o instanceof ExcludesConfigurationState)) return false;

  ExcludesConfigurationState state = (ExcludesConfigurationState)o;
  return myDetectionEnabled == state.myDetectionEnabled && Comparing.haveEqualElements(myFiles, state.myFiles)
         && Comparing.haveEqualElements(myFrameworkTypes, state.myFrameworkTypes);
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:10,代码来源:ExcludesConfigurationState.java

示例5: checkIfAlreadyOpened

import com.intellij.openapi.util.Comparing; //导入方法依赖的package包/类
private static boolean checkIfAlreadyOpened(@NotNull ContentManager cm, @NotNull Collection<VirtualFile> roots) {
  for (Content content : cm.getContents()) {
    final JComponent component = content.getComponent();
    if (component instanceof MyContentComponent) {
      if (Comparing.haveEqualElements(roots, ((MyContentComponent)component).myRoots)) {
        cm.setSelectedContent(content);
        return true;
      }
    }
  }
  return false;
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:13,代码来源:GitShowExternalLogAction.java

示例6: shouldRunProgress

import com.intellij.openapi.util.Comparing; //导入方法依赖的package包/类
protected boolean shouldRunProgress() {
  return myLastRoots == null || !Comparing.haveEqualElements(myLastRoots, getRoots());
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:4,代码来源:FrameworkDetectionStep.java


注:本文中的com.intellij.openapi.util.Comparing.haveEqualElements方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。