Package org.jresponder.service

Examples of org.jresponder.service.ServiceException


    try {
      Object ret = JSONValue.parseWithException(aParamJson);
      params = ((Map<String,Object>)ret);
    }
    catch (Exception e) {
      throw new ServiceException(ServiceExceptionType.INVALID_PARAMS, e);
    }

  }
View Full Code Here


    assert(aParamName != null);
    Object myValue = params.get(aParamName);
    if (myValue != null) {
      return myValue.toString();
    }
    throw new ServiceException(ServiceExceptionType.PARAM_REQUIRED,
        PropUtil.getInstance().mkprops("name", aParamName));
  }
View Full Code Here

    if (myValue != null) {
      try {
        return Long.parseLong(myValue.toString());
      }
      catch (NumberFormatException e) {
        throw new ServiceException(ServiceExceptionType.PARAM_BAD_FORMAT, e);
      }
     
    }
    return aDefault;
View Full Code Here

    if (myValue != null) {
      try {
        return Long.parseLong(myValue.toString());
      }
      catch (NumberFormatException e) {
        throw new ServiceException(ServiceExceptionType.PARAM_BAD_FORMAT, e);
      }
     
    }
    throw new ServiceException(ServiceExceptionType.PARAM_REQUIRED,
        PropUtil.getInstance().mkprops("name", aParamName));
  }
View Full Code Here

    assert(aParamName != null);
    Object myValue = params.get(aParamName);
    if (myValue != null) {
      return (Map<String,Object>)myValue;
    }
    throw new ServiceException(ServiceExceptionType.PARAM_REQUIRED,
        PropUtil.getInstance().mkprops("name", aParamName));
  }
View Full Code Here

TOP

Related Classes of org.jresponder.service.ServiceException

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.