org.apache.ignite.internal.util.typedef.F.t()方法的使用及代码示例

x33g5p2x  于2022-01-19 转载在 其他  
字(5.0k)|赞(0)|评价(0)|浏览(87)

本文整理了Java中org.apache.ignite.internal.util.typedef.F.t()方法的一些代码示例,展示了F.t()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。F.t()方法的具体详情如下:
包路径:org.apache.ignite.internal.util.typedef.F
类名称:F
方法名:t

F.t介绍

暂无

代码示例

代码示例来源:origin: apache/ignite

/**
 * @return Current value and stamp.
 */
public IgniteBiTuple<T, S> get() {
  return F.t(val, stamp);
}

代码示例来源:origin: apache/ignite

@Override public IgniteBiTuple<? extends CacheObject, GridCacheVersion> apply(CacheObject val) {
    return F.t(val, ver);
  }
});

代码示例来源:origin: apache/ignite

/**
 * Swaps values.
 *
 * @return New tuple with swapped values.
 */
public IgniteBiTuple<V2, V1> swap() {
  return F.t(val2, val1);
}

代码示例来源:origin: apache/ignite

/**
 * Adds configuration to bind on. Should not be called after thread start.
 *
 * @param cfg Configuration.
 * @param mgmt Management flag.
 */
public void addConfiguration(IgfsIpcEndpointConfiguration cfg, boolean mgmt) {
  bindCfgs.add(F.t(cfg, mgmt));
}

代码示例来源:origin: apache/ignite

/**
 * @param msg Message to add.
 * @param msgC Message closure (may be {@code null}).
 */
void add(
  GridIoMessage msg,
  @Nullable IgniteRunnable msgC
) {
  msgs.add(F.t(msg, U.currentTimeMillis(), msgC));
}

代码示例来源:origin: apache/ignite

/**
 * @param mode Call mode.
 * @param job Job.
 */
private T7(GridClosureCallMode mode, Callable<R> job) {
  super(U.peerDeployAware(job));
  t = F.t(mode, job);
}

代码示例来源:origin: apache/ignite

/**
 * Process started callback.
 */
public void onProcessStarted(Process proc) {
  this.proc = proc;
  procStarted = true;
  if (procStarted && replyReceived)
    onDone(F.t(proc, desc));
}

代码示例来源:origin: apache/ignite

/**
 * Gracefully stops worker by adding STOP_INFO to queue.
 */
private void stop() {
  delReqs.offer(F.t(new GridFutureAdapter<>(), stopInfo));
}

代码示例来源:origin: apache/ignite

/**
 * @param info File info to delete.
 * @return Future which completes when entry is actually removed.
 */
private IgniteInternalFuture<Object> deleteAsync(IgfsEntryInfo info) {
  GridFutureAdapter<Object> fut = new GridFutureAdapter<>();
  delReqs.offer(F.t(fut, info));
  return fut;
}

代码示例来源:origin: apache/ignite

/**
 * @param mode Call mode.
 * @param jobs Collection of jobs.
 */
private T1(GridClosureCallMode mode, Collection<? extends Runnable> jobs) {
  super(U.peerDeployAware0(jobs));
  t = F.<
    GridClosureCallMode,
    Collection<? extends Runnable>
    >t(mode, jobs);
}

代码示例来源:origin: apache/ignite

/**
 * @param mode Call mode.
 * @param job Job.
 */
private T2(GridClosureCallMode mode, Runnable job) {
  super(U.peerDeployAware(job));
  t = F.t(mode, job);
}

代码示例来源:origin: apache/ignite

/**
 *
 * @param mode Call mode.
 * @param jobs Collection of jobs.
 * @param rdc Reducer.
 */
private T3(GridClosureCallMode mode, Collection<? extends Callable<R1>> jobs, IgniteReducer<R1, R2> rdc) {
  super(U.peerDeployAware0(jobs));
  t = F.<
    GridClosureCallMode,
    Collection<? extends Callable<R1>>,
    IgniteReducer<R1, R2>
    >t(mode, jobs, rdc);
}

代码示例来源:origin: apache/ignite

/**
 * Reply received callback.
 */
public void onReplyReceived(HadoopProcessDescriptor desc) {
  assert childProcId.equals(desc.processId());
  this.desc = desc;
  replyReceived = true;
  if (procStarted && replyReceived)
    onDone(F.t(proc, desc));
}

代码示例来源:origin: apache/ignite

/**
 * Field for index state check.
 *
 * @param name Name.
 * @param asc Ascending flag.
 * @return Field.
 */
protected static IgniteBiTuple<String, Boolean> field(String name, boolean asc) {
  return F.t(name.toUpperCase(), asc);
}

代码示例来源:origin: apache/ignite

/**
   * Reset summary  counters.
   */
  void reset() {
    blocksRead = F.t(new LongAdder(), new LongAdder());
    blocksWritten = F.t(new LongAdder(), new LongAdder());
    bytesRead = F.t(new LongAdder(), new LongAdder());
    bytesWritten = F.t(new LongAdder(), new LongAdder());
  }
}

代码示例来源:origin: apache/ignite

/** {@inheritDoc} */
@Nullable @Override public IgniteBiTuple<Long, Long> reduce(List<ComputeJobResult> results) {
  long used = 0;
  long max = 0;
  for (ComputeJobResult res : results) {
    IgniteBiTuple<Long, Long> data = res.getData();
    if (data != null) {
      used += data.get1();
      max += data.get2();
    }
  }
  return F.t(used, max);
}

代码示例来源:origin: apache/ignite

@Nullable @Override public IgniteBiTuple<Long, Long> execute() {
    IgniteFileSystem igfs = ((IgniteKernal)g).context().igfs().igfs(igfsName);
    if (igfs == null)
      return F.t(0L, 0L);
    IgfsMetrics metrics = igfs.metrics();
    long loc = metrics.localSpaceSize();
    return F.t(loc, metrics.maxSpaceSize());
  }
});

代码示例来源:origin: apache/ignite

/**
   * @param name Field name.
   * @param val Value.
   */
  private void value(String name, Object val) {
    int i = curFields.getIndex(name);
    OptimizedClassDescriptor.FieldInfo info = curFields.get(i);
    objs[i] = F.t(info.type(), val);
  }
}

代码示例来源:origin: apache/ignite

/** {@inheritDoc} */
@Nullable @Override public GridTuple<CacheObject> peek(
  GridCacheContext cacheCtx,
  boolean failFast,
  KeyCacheObject key
) throws GridCacheFilterFailedException {
  IgniteTxEntry e = entry(cacheCtx.txKey(key));
  if (e != null)
    return e.hasPreviousValue() ? F.t(e.previousValue()) : null;
  return null;
}

代码示例来源:origin: apache/ignite

/**
 * Tests correct behavior in case of 1 REST-enabled node
 * with explicitly specified loopback address setting.
 *
 * @throws Exception If error occurs.
 */
@Test
public void testOneNodeLoopbackHost() throws Exception {
  startRestNode("grid1", LOOPBACK_IP, defaultRestPort());
  checkConnectivityByIp(LOOPBACK_IP, F.t((Collection<String>)Collections.singleton(LOOPBACK_IP),
    (Collection<String>)Collections.<String>emptySet()));
}

相关文章