Package gnu.trove

Examples of gnu.trove.TIntHashSet.toArray()


    long start = System.nanoTime();
    TIntHashSet localTrigrams = lexText(buf);
    stats.time += System.nanoTime() - start;
    stats.maxtrigrams = Math.max(stats.maxtrigrams, localTrigrams.size());
    int[] graphs = localTrigrams.toArray();
    stats.allTrigrams.addAll(graphs);
    for (int graph : graphs) {
      List<File> list = stats.filesMap.get(graph);
      if (list == null) {
        list = new ArrayList<File>();
View Full Code Here


    }
    TIntHashSet items = myMulti.get(key);
    if (items != null) {
      items.remove(value);
      if (items.size() == 1) {
        mySingle.put(key, items.toArray()[0]);
        myMulti.remove(key);
      }
    }
  }
View Full Code Here

    if (mySingle.containsKey(key)) {
      return new int[]{mySingle.get(key)};
    }
    TIntHashSet items = myMulti.get(key);
    if (items == null) return ArrayUtil.EMPTY_INT_ARRAY;
    return items.toArray();
  }
}
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.