當前位置: 首頁>>代碼示例>>Java>>正文


Java NonBlockingHashMapLong類代碼示例

本文整理匯總了Java中water.nbhm.NonBlockingHashMapLong的典型用法代碼示例。如果您正苦於以下問題:Java NonBlockingHashMapLong類的具體用法?Java NonBlockingHashMapLong怎麽用?Java NonBlockingHashMapLong使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


NonBlockingHashMapLong類屬於water.nbhm包,在下文中一共展示了NonBlockingHashMapLong類的14個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: toString

import water.nbhm.NonBlockingHashMapLong; //導入依賴的package包/類
@Override public String toString() {
  StringBuilder sb = new StringBuilder();
  for( NonBlockingHashMapLong.IteratorLong i = iter(_col0s); i.hasNext(); ) {
    long l = i.nextLong();
    double d = Double.longBitsToDouble(l);
    sb.append(d).append(": {");
    NonBlockingHashMapLong<AtomicLong> col1s = _col0s.get(l);
    for( NonBlockingHashMapLong.IteratorLong j = iter(col1s); j.hasNext(); ) {
      long l2 = j.nextLong();
      double d2 = Double.longBitsToDouble(l2);
      AtomicLong al = col1s.get(l2);
      sb.append(d2).append(": ").append(al.get()).append(", ");
    }
    sb.append("}\n");
  }
  return sb.toString();
}
 
開發者ID:kyoren,項目名稱:https-github.com-h2oai-h2o-3,代碼行數:18,代碼來源:ASTTable.java

示例2: toString

import water.nbhm.NonBlockingHashMapLong; //導入依賴的package包/類
@Override
public String toString() {
  StringBuilder sb = new StringBuilder();
  for (NonBlockingHashMapLong.IteratorLong i = iter(_col0s); i.hasNext(); ) {
    long l = i.nextLong();
    double d = Double.longBitsToDouble(l);
    sb.append(d).append(": {");
    NonBlockingHashMapLong<AtomicLong> col1s = _col0s.get(l);
    for (NonBlockingHashMapLong.IteratorLong j = iter(col1s); j.hasNext(); ) {
      long l2 = j.nextLong();
      double d2 = Double.longBitsToDouble(l2);
      AtomicLong al = col1s.get(l2);
      sb.append(d2).append(": ").append(al.get()).append(", ");
    }
    sb.append("}\n");
  }
  return sb.toString();
}
 
開發者ID:h2oai,項目名稱:h2o-3,代碼行數:19,代碼來源:AstTable.java

示例3: collectDomain

import water.nbhm.NonBlockingHashMapLong; //導入依賴的package包/類
private static double[] collectDomain( NonBlockingHashMapLong ls ) {
  int sz = ls.size();         // Uniques
  double ds[] = new double[sz];
  int x=0;
  for( NonBlockingHashMapLong.IteratorLong i = iter(ls); i.hasNext(); )
    ds[x++] = Double.longBitsToDouble(i.nextLong());
  Arrays.sort(ds);
  return ds;
}
 
開發者ID:kyoren,項目名稱:https-github.com-h2oai-h2o-3,代碼行數:10,代碼來源:ASTTable.java

示例4: write_impl

import water.nbhm.NonBlockingHashMapLong; //導入依賴的package包/類
@Override public AutoBuffer write_impl(AutoBuffer ab) {
  if( _col0s == null ) return ab.put8(0);
  ab.put8(_col0s.size());
  for( long col0 : _col0s.keySetLong() ) {
    ab.put8(col0);
    NonBlockingHashMapLong<AtomicLong> col1s = _col0s.get(col0);
    ab.put8(col1s.size());
    for( long col1 : col1s.keySetLong() ) {
      ab.put8(col1);
      ab.put8(col1s.get(col1).get());
    }
  }
  return ab;
}
 
開發者ID:kyoren,項目名稱:https-github.com-h2oai-h2o-3,代碼行數:15,代碼來源:ASTTable.java

示例5: read_impl

import water.nbhm.NonBlockingHashMapLong; //導入依賴的package包/類
@Override public SlowCnt read_impl(AutoBuffer ab) {
  long len0 = ab.get8();
  if( len0 == 0 ) return this;
  _col0s = new NonBlockingHashMapLong<>();
  for( long i=0; i<len0; i++ ) {
    NonBlockingHashMapLong<AtomicLong> col1s = new NonBlockingHashMapLong<>();
    _col0s.put(ab.get8(),col1s);
    long len1 = ab.get8();
    for( long j=0; j<len1; j++ )
      col1s.put(ab.get8(),new AtomicLong(ab.get8()));
  }
  return this;
}
 
開發者ID:kyoren,項目名稱:https-github.com-h2oai-h2o-3,代碼行數:14,代碼來源:ASTTable.java

示例6: collectDomain

import water.nbhm.NonBlockingHashMapLong; //導入依賴的package包/類
private static double[] collectDomain(NonBlockingHashMapLong ls) {
  int sz = ls.size();         // Uniques
  double ds[] = new double[sz];
  int x = 0;
  for (NonBlockingHashMapLong.IteratorLong i = iter(ls); i.hasNext(); )
    ds[x++] = Double.longBitsToDouble(i.nextLong());
  Arrays.sort(ds);
  return ds;
}
 
開發者ID:h2oai,項目名稱:h2o-3,代碼行數:10,代碼來源:AstTable.java

示例7: write_impl

import water.nbhm.NonBlockingHashMapLong; //導入依賴的package包/類
public final AutoBuffer write_impl(AutoBuffer ab) {
  if (_col0s == null) return ab.put8(0);
  ab.put8(_col0s.size());
  for (long col0 : _col0s.keySetLong()) {
    ab.put8(col0);
    NonBlockingHashMapLong<AtomicLong> col1s = _col0s.get(col0);
    ab.put8(col1s.size());
    for (long col1 : col1s.keySetLong()) {
      ab.put8(col1);
      ab.put8(col1s.get(col1).get());
    }
  }
  return ab;
}
 
開發者ID:h2oai,項目名稱:h2o-3,代碼行數:15,代碼來源:AstTable.java

示例8: read_impl

import water.nbhm.NonBlockingHashMapLong; //導入依賴的package包/類
public final AstTable.SlowCnt read_impl(AutoBuffer ab) {
  long len0 = ab.get8();
  if (len0 == 0) return this;
  _col0s = new NonBlockingHashMapLong<>();
  for (long i = 0; i < len0; i++) {
    NonBlockingHashMapLong<AtomicLong> col1s = new NonBlockingHashMapLong<>();
    _col0s.put(ab.get8(), col1s);
    long len1 = ab.get8();
    for (long j = 0; j < len1; j++)
      col1s.put(ab.get8(), new AtomicLong(ab.get8()));
  }
  return this;
}
 
開發者ID:h2oai,項目名稱:h2o-3,代碼行數:14,代碼來源:AstTable.java

示例9: iter

import water.nbhm.NonBlockingHashMapLong; //導入依賴的package包/類
private static NonBlockingHashMapLong.IteratorLong iter(NonBlockingHashMapLong nbhml) { 
  return (NonBlockingHashMapLong.IteratorLong)nbhml.keySet().iterator();  
}
 
開發者ID:kyoren,項目名稱:https-github.com-h2oai-h2o-3,代碼行數:4,代碼來源:ASTTable.java

示例10: iter

import water.nbhm.NonBlockingHashMapLong; //導入依賴的package包/類
private static NonBlockingHashMapLong.IteratorLong iter(NonBlockingHashMapLong nbhml) {
  return (NonBlockingHashMapLong.IteratorLong) nbhml.keySet().iterator();
}
 
開發者ID:h2oai,項目名稱:h2o-3,代碼行數:4,代碼來源:AstTable.java

示例11: setupLocal

import water.nbhm.NonBlockingHashMapLong; //導入依賴的package包/類
@Override
public void setupLocal() {
  _col0s = new NonBlockingHashMapLong<>();
}
 
開發者ID:h2oai,項目名稱:h2o-3,代碼行數:5,代碼來源:AstTable.java

示例12: setupLocal

import water.nbhm.NonBlockingHashMapLong; //導入依賴的package包/類
@Override protected void setupLocal() { _uniques = new NonBlockingHashMapLong<>(); } 
開發者ID:kyoren,項目名稱:https-github.com-h2oai-h2o-3,代碼行數:2,代碼來源:Vec.java

示例13: setupLocal

import water.nbhm.NonBlockingHashMapLong; //導入依賴的package包/類
@Override public void setupLocal() {  _col0s = new NonBlockingHashMapLong<>();  } 
開發者ID:kyoren,項目名稱:https-github.com-h2oai-h2o-3,代碼行數:2,代碼來源:ASTTable.java

示例14: setupLocal

import water.nbhm.NonBlockingHashMapLong; //導入依賴的package包/類
@Override protected void setupLocal() { _uniques = new NonBlockingHashMapLong(); } 
開發者ID:h2oai,項目名稱:h2o-2,代碼行數:2,代碼來源:Vec.java


注:本文中的water.nbhm.NonBlockingHashMapLong類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。