Package com.alibaba.jstorm.stats.rolling

Examples of com.alibaba.jstorm.stats.rolling.UpdateParams


  @SuppressWarnings("unchecked")
  @Override
  public <T> Object execute(T... args) {
    Map<Object, Long> curr = null;
    if (args != null && args.length > 0) {
      UpdateParams p = (UpdateParams) args[0];
      if (p.getCurr() != null) {
        curr = (Map<Object, Long>) p.getCurr();
      } else {
        curr = new HashMap<Object, Long>();
      }
      Object[] incArgs = p.getArgs();

      Long amt = 1l;

      if (incArgs.length > 1) {
        amt = Long.parseLong(String.valueOf(incArgs[1]));
View Full Code Here


  @SuppressWarnings("unchecked")
  @Override
  public <T> Object execute(T... args) {
    Map<Object, Pair<Long, Long>> curr = null;
    if (args != null && args.length > 0) {
      UpdateParams p = (UpdateParams) args[0];
      if (p.getCurr() != null) {
        curr = (Map<Object, Pair<Long, Long>>) p.getCurr();
      } else {
        curr = new HashMap<Object, Pair<Long, Long>>();
      }
      Object[] keyAvgArgs = p.getArgs();

      Long amt = 1l;
      if (keyAvgArgs.length > 1) {
        amt = Long.parseLong(String.valueOf(keyAvgArgs[1]));
      }
View Full Code Here

TOP

Related Classes of com.alibaba.jstorm.stats.rolling.UpdateParams

Copyright © 2018 www.massapicom. 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.