Attempt to parse the given object as a set of parameters for this handler.

@param params the parameter block to parse
@return true if the object made sense for this handler; false otherwise.
420947
@Override
    public boolean parseParameters(Object params) {
        super.parseParameters(params);
        if (params == null || !(params instanceof RewardForSendingMatchingChatMessage))
            return false;

        this.params = (RewardForSendingMatchingChatMessage) params;
        for (ChatMatchSpec cm : this.params.getChatMatch())
            addChatMatchSpecToRewardStructure(cm);

        return true;
    }
91482
public static void checkNullTypedParams(String url, ApiRequestParams params) {
    if (params == null) {
      throw new IllegalArgumentException(String.format("Found null params for %s. "
          + "Please pass empty params using param builder via `builder().build()` instead.", url
      ));
    }
  }
1104249
public boolean getParamBoolean(String paramName) {
        Object paramValue = getParam(paramName);
        if (paramValue == null) {
            return false;
        }
        return Boolean.parseBoolean(paramValue.toString());
    }
727248
public java.util.Collection<String> getParam(String paramName) {
        return this.params.get(paramName);
    }
53451
protected final void loadQueryString(Map<String, String[]> params) {
        for (Map.Entry<String, String[]> param : params.entrySet()) {
            loadKeys(param.getKey(), param.getValue());
        }
    }
861617
protected static void validateParamsPresence(Map params, String... keys) {
        for (String name : keys) {
            if (!params.containsKey(name)) {
                throw new IllegalArgumentException("parameter: '" + name + "' is missing");
            }
        }
    }
156113
public void setParams(List<AstNode> params) {
        if (params == null) {
            this.params = null;
        } else {
            if (this.params != null)
                this.params.clear();
            for (AstNode param : params)
                addParam(param);
        }
    }
296498
protected boolean validate(T obj) throws ParameterException {
    if(constraints != null) {
      for(ParameterConstraint<? super T> cons : this.constraints) {
        cons.test(obj);
      }
    }
    return true;
  }
255372
public static boolean checkParam(Map<String, String> params, String key) {
        boolean result = false;
        if (params.containsKey("sign")) {
            String sign = params.get("sign");
            params.remove("sign");
            StringBuilder buf = new StringBuilder((params.size() + 1) * 10);
            SignUtils.buildPayParams(buf, params, false);
            String preStr = buf.toString();
            String signReceive = MD5Utils.sign(preStr, "&key=" + key, "utf-8");
            result = sign.equalsIgnoreCase(signReceive);
        }
        return result;
    }
227235
public static String getOptionalStringParam(JSONObject params, String paramName) {
		if (params.containsKey(paramName)) {
			return params.getString(paramName);
		}
		return null;
	}
580567
public Object func(String param) {
		ReqInfo reqInfo = ContextUtils.getReqInfo();

		StringBuffer sb = new StringBuffer();
		// if (reqInfo.m_bUseAjax)
		// sb.append("document.");
		sb.append(param);
		sb.append(reqInfo.getRequestId());
		return sb.toString();
	}
481477
long parseParam(final String param) {
    if (param == null || param.isEmpty()) {
      throw new IllegalArgumentException(
          "Window parameter may not be null or empty");
    }
    final char[] chars = param.toCharArray();
    int idx = 0;
    for (int c = 1; c < chars.length; c++) {
      if (Character.isDigit(chars[c])) {
        idx++;
      } else {
        break;
      }
    }
    if (idx < 1) {
      throw new IllegalArgumentException("Invalid moving window parameter: " 
          + param);
    }

    try {
      final int time = Integer.parseInt(param.substring(1, idx + 1));
      final String unit = param.substring(idx + 1, param.length() - 1);
  
      // TODO(CL) - add a Graphite unit parser to DateTime for this kind of conversion
      if ("day".equals(unit) || "d".equals(unit)) {
        return TimeUnit.MILLISECONDS.convert(time, TimeUnit.DAYS);
      } else if ("hr".equals(unit) || "hour".equals(unit) || "h".equals(unit)) {
        return TimeUnit.MILLISECONDS.convert(time, TimeUnit.HOURS);
      } else if ("min".equals(unit) || "m".equals(unit)) {
        return TimeUnit.MILLISECONDS.convert(time, TimeUnit.MINUTES); 
      } else if ("sec".equals(unit) || "s".equals(unit)) {
        return TimeUnit.MILLISECONDS.convert(time, TimeUnit.SECONDS);
      } else {
        throw new IllegalArgumentException("Unknown time unit=" + unit 
            + " in window=" + param);
      }
    } catch (NumberFormatException nfe) {
      throw new IllegalArgumentException("Unable to parse moving window "
          + "parameter: " + param, nfe);
    }
  }
88081
public static boolean hasQueryParam(String param, ContainerRequestContext ctx) {
		return ctx.getUriInfo().getQueryParameters().containsKey(param);
	}
935383
def parse_parameters(self, parameters):
        """"""

        self.parameters = []
        for param_name, param_value in parameters.items():
            p = Parameter(param_name, param_value)
            if p:
                self.parameters.append(p)
261253
public final void call(T param)
	{
		if (!run)
		{
			run = true;
			prepared = true;

			try
			{
				this.run(param);
			}
			catch (Throwable t)
			{
				log.error("[ParamInvokeable] {prepare} : " + t.getMessage(), t);
			}
		}
	}
140052
public static Map<String, String> getUrlParams(String param) {
        Map<String, String> map = new HashMap<String, String>();
        if (StringUtils.isEmpty(param)) {
            return map;
        }
        String[] params = param.split("&");
        for (int i = 0; i < params.length; i++) {
            String[] p = params[i].split("=");
            if (p.length == 2) {
                map.put(p[0], p[1]);
            }
        }
        return map;
    }
163882
private static StringMap filterParam(StringMap params) {
        final StringMap ret = new StringMap();
        if (params == null) {
            return ret;
        }
        params.forEach(new StringMap.Consumer() {
            @Override
            public void accept(String key, Object value) {
                if (value == null) {
                    return;
                }
                String val = value.toString();
                if ((key.startsWith("x:") || key.startsWith("x-qn-meta-")) && !val.equals("")) {
                    ret.put(key, val);
                }
            }
        });
        return ret;
    }