Class FileMaker_Error_Validation

Description

Extension of the FileMaker_Error class that adds information about pre-validation errors.

Located in /FileMaker/Error/Validation.php (line 28)

PEAR_Error
   |
   --FileMaker_Error
      |
      --FileMaker_Error_Validation
Method Summary
void addError (FileMaker_Field $field, integer $rule, string $value)
array getErrors ([string $fieldName = null])
boolean isValidationError ()
integer numErrors ()
Methods
addError (line 46)

Adds an error.

void addError (FileMaker_Field $field, integer $rule, string $value)
  • FileMaker_Field $field: Field object that failed pre-validation.
  • integer $rule: Pre-validation rule that failed specified as one of the FILEMAKER_RULE_* constants.
  • string $value: Value that failed pre-validation.
getErrors (line 94)

Returns an array of arrays describing the pre-validation errors that occurred.

Each entry in the outer array represents a pre-validation failure. Each failure is represented by a three-element array with the following members:

  • 0 => The field object for the field that failed pre-validation.
  • 1 => The pre-validation rule that failed specified as a FILEMAKER_RULE_* constant.
  • 2 => The value entered for the field that failed pre-validation.
Multiple pre-validation rules can fail on a single field. If you set the optional $fieldName parameter, then failures for only the specified field are returned.

  • return: Pre-validation error details.
array getErrors ([string $fieldName = null])
  • string $fieldName: Name of the field to get errors for.
isValidationError (line 58)

Indicates whether the error is a detailed pre-validation error or a FileMaker Web Publishing Engine error.

  • return: TRUE, to indicate that this is a pre-validation error object.
boolean isValidationError ()

Redefinition of:
FileMaker_Error::isValidationError()
Indicates whether the error is a detailed pre-validation error or a FileMaker Web Publishing Engine error.
numErrors (line 68)

Returns the number of pre-validation rules that failed.

  • return: Number of failures.
integer numErrors ()

Inherited Methods

Inherited From FileMaker_Error

FileMaker_Error::FileMaker_Error()
FileMaker_Error::getErrorString()
FileMaker_Error::getMessage()
FileMaker_Error::isValidationError()

Documentation generated on Tue, 22 May 2007 13:39:09 -0700 by phpDocumentor 1.3.1