Package com.agiletec.aps.system.common.entity.model

Examples of com.agiletec.aps.system.common.entity.model.AttributeFieldError


            List<FieldError> fieldErrors = userMessage.validate(this.getGroupManager());
            if (null != fieldErrors) {
                for (int i = 0; i < fieldErrors.size(); i++) {
                    FieldError fieldError = fieldErrors.get(i);
                    if (fieldError instanceof AttributeFieldError) {
                        AttributeFieldError attributeError = (AttributeFieldError) fieldError;
                        errors.add(new ApiError(IApiErrorCodes.API_VALIDATION_ERROR,
                attributeError.getFullMessage(), Response.Status.CONFLICT));
                    } else {
                        errors.add(new ApiError(IApiErrorCodes.API_VALIDATION_ERROR,
                fieldError.getMessage(), Response.Status.CONFLICT));
                    }
                }
View Full Code Here


        }
        String coords = area.getCoords();
        boolean isShapeValued = (area.getShape() != null && area.getShape().trim().length() > 0 );
        boolean isCoordsValued = (coords!= null && coords.trim().length() > 0 && this.isValidNumber(coords));
        if (!isShapeValued || !isCoordsValued) {
          errors.add(new AttributeFieldError(this, INVALID_LINKED_AREA_ERROR, areaTracer));
          /*
          String formFieldName = tracer.getFormFieldName(imageMapAttribute);
          String[] args = { imageMapAttribute.getName(), String.valueOf(tracer.getListIndex()+1) };
          this.addFieldError(action, formFieldName, "Content.linkedAreaElement.invalidArea.maskmsg", args);
           */
 
View Full Code Here

      Integer[] currentCoordsArray = currentArea.getArrayCoords();
      Rectangle currentAreaRect = new Rectangle(currentCoordsArray[0].intValue(),currentCoordsArray[1].intValue(),
          currentCoordsArray[2].intValue() - currentCoordsArray[0].intValue() , currentCoordsArray[3].intValue() - currentCoordsArray[1].intValue());
      boolean intersect = areaRect.intersects(currentAreaRect);
      if (intersect) {
        errors.add(new AttributeFieldError(this, INVALID_LINKED_AREA_ERROR, tracer));
      }
    }
  }
View Full Code Here

TOP

Related Classes of com.agiletec.aps.system.common.entity.model.AttributeFieldError

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.