Пример #1
0
 public void changeGoodProperty(
     @WebParam(name = "id") Long id,
     @WebParam(name = "property") GoodProperty property,
     @WebParam(name = "newValue") String newValue)
     throws WebServiceException {
   if (id == null || id == 0)
     throw new WebServiceException(Constants.objectIsNull, "ID is null or empty");
   if (property == null || newValue == null || newValue.trim().length() == 0)
     throw new WebServiceException(
         Constants.fieldNotFilledProperly, "PropertyName or newValue is NULL");
   try {
     bean.changeGoodProperty(id, property, newValue);
   } catch (ServicesException ex) {
     throw new WebServiceException(ex.getErrorCode(), ex.getComment());
   }
 }