ValidForm::ValidationError (Class)

In: ValidForm.rb
Parent: Object

Describes a single validation error that occurred with a field. Each field may have more than one ::ValidationError after a call to ::Field#validate; see ::Field#errors for more information.

Methods

new  

Constants

REQUIRED_VALUE_EMPTY = :REQUIRED_VALUE_EMPTY
LENGTH_TOO_SMALL = :LENGTH_TOO_SMALL
LENGTH_TOO_LARGE = :LENGTH_TOO_LARGE
MATCH_FAIL_PHONE = :MATCH_FAIL_PHONE
MATCH_FAIL_EMAIL = :MATCH_FAIL_EMAIL
MATCH_FAIL_ZIPCODE = :MATCH_FAIL_ZIPCODE
MATCH_FAIL_INTEGER = :MATCH_FAIL_INTEGER
MATCH_FAIL_FLOAT = :MATCH_FAIL_FLOAT
MATCH_FAIL_DATE = :MATCH_FAIL_DATE
MATCH_FAIL_TIME = :MATCH_FAIL_TIME
MATCH_FAIL_DATETIME = :MATCH_FAIL_DATETIME
MATCH_FAIL_CUSTOM = :MATCH_FAIL_CUSTOM
VALUE_TOO_SMALL = :VALUE_TOO_SMALL
VALUE_TOO_LARGE = :VALUE_TOO_LARGE
DATETIME_TOO_SMALL = :DATETIME_TOO_SMALL
DATETIME_TOO_LARGE = :DATETIME_TOO_LARGE
TOO_FEW_CHOSEN = :TOO_FEW_CHOSEN
TOO_MANY_CHOSEN = :TOO_MANY_CHOSEN

Attributes

field  [R]  The field this error is associated with.
msg  [R]  A message that describes the error.
type  [R]  One of the error constants of this class.
value  [R]  The value of the field when the error occurred.

Public Class methods

field:A reference to the field that is invalid. [reqd]
errorType:One of the error constants associated with this class. [reqd]

[Validate]