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


Java TIntIntProcedure类代码示例

本文整理汇总了Java中gnu.trove.TIntIntProcedure的典型用法代码示例。如果您正苦于以下问题:Java TIntIntProcedure类的具体用法?Java TIntIntProcedure怎么用?Java TIntIntProcedure使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


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

示例1: getResult

import gnu.trove.TIntIntProcedure; //导入依赖的package包/类
public Map<IdIndexEntry, Integer> getResult() {
  final Map<IdIndexEntry, Integer> result = new THashMap<IdIndexEntry, Integer>(myResult.size());
  myResult.forEachEntry(new TIntIntProcedure() {
    @Override
    public boolean execute(final int key, final int value) {
      result.put(new IdIndexEntry(key), value);
      return true;
    }
  });

  return result;
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:13,代码来源:IdDataConsumer.java

示例2: getCurrentModalityCount

import gnu.trove.TIntIntProcedure; //导入依赖的package包/类
private int getCurrentModalityCount() {
  int modalityCount = 0;
  Window[] windows = Window.getWindows();
  for (Window each : windows) {
    if (!each.isShowing()) continue;

    if (each instanceof Dialog) {
      Dialog eachDialog = (Dialog)each;
      if (eachDialog.isModal()) {
        modalityCount++;
      }
      else if (each instanceof JDialog) {
        if (isModalContextPopup(((JDialog)each).getRootPane())) {
          modalityCount++;
        }
      }
    }
    else if (each instanceof JWindow) {
      JRootPane rootPane = ((JWindow)each).getRootPane();
      if (isModalContextPopup(rootPane)) {
        modalityCount++;
      }
    }
  }
  final int finalModalityCount = modalityCount;
  myModalityCount2FlushCount.retainEntries(new TIntIntProcedure() {
    @Override
    public boolean execute(int eachModalityCount, int flushCount) {
      return eachModalityCount <= finalModalityCount;
    }
  });

  return modalityCount;
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:35,代码来源:FocusManagerImpl.java

示例3: hasOtherModifiers

import gnu.trove.TIntIntProcedure; //导入依赖的package包/类
private boolean hasOtherModifiers(KeyEvent keyEvent) {
  final int modifiers = keyEvent.getModifiers();
  return !KEY_CODE_TO_MODIFIER_MAP.forEachEntry(new TIntIntProcedure() {
    @Override
    public boolean execute(int keyCode, int modifierMask) {
      return keyCode == myModifierKeyCode || (modifiers & modifierMask) == 0;
    }
  });
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:10,代码来源:ModifierKeyDoubleClickHandler.java

示例4: putAll

import gnu.trove.TIntIntProcedure; //导入依赖的package包/类
@Override
public void putAll(final IntIntMaplet m) {
  m.forEachEntry(new TIntIntProcedure() {
    @Override
    public boolean execute(int key, int value) {
      myMap.put(key, value);
      return true;
    }
  });
}
 
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:11,代码来源:IntIntTransientMaplet.java

示例5: putAll

import gnu.trove.TIntIntProcedure; //导入依赖的package包/类
@Override
public void putAll(final IntIntMaplet m) {
  m.forEachEntry(new TIntIntProcedure() {
    @Override
    public boolean execute(int key, int value) {
      put(key, value);
      return true;
    }
  });
}
 
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:11,代码来源:IntIntPersistentMaplet.java

示例6: forEachEntry

import gnu.trove.TIntIntProcedure; //导入依赖的package包/类
@Override
public void forEachEntry(TIntIntProcedure proc) {
  myMap.forEachEntry(proc);
}
 
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:5,代码来源:IntIntTransientMaplet.java

示例7: forEachEntry

import gnu.trove.TIntIntProcedure; //导入依赖的package包/类
abstract void forEachEntry(TIntIntProcedure proc); 
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:2,代码来源:IntIntMaplet.java


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