ValueType represents the type that users will work with.
ValueType represents the type that users will work with. For OptionalTypedField, this is equal to Option[ThisType].
Helper for implementing asJValue for a conversion to an encoded JString
Helper for implementing asJValue for a conversion to an encoded JString
function to transform the field value into a String
Encode the field value into a JValue
Encode the field value into a JValue
Returns the field's value as a valid JavaScript expression
Returns the field's value as a valid JavaScript expression
Convert the field to a String...
Convert the field to a String... usually of the form "displayName=value"
Can the value of this field be read without obscuring the result?
Can the value of this field be read without obscuring the result?
Can the value of this field be written?
Can the value of this field be written?
If the owner is not in "safe" mode, check the current environment to see if the field can be read
If the owner is not in "safe" mode, check the current environment to see if the field can be read
If the owner is not in "safe" mode, check the current environment to see if the field can be written
If the owner is not in "safe" mode, check the current environment to see if the field can be written
Clear the value of this field
Clear the value of this field
The default value of the field when no value is set.
The default value of the field when no value is set. Must return a Full Box unless optional_? is true
The display name of this field (e.g., "First Name")
The display name of this field (e.g., "First Name")
Should the dirty flag always be set when setBox is called
Should the dirty flag always be set when setBox is called
What form elements are we going to add to this field?
What form elements are we going to add to this field?
Form field's type.
Form field's type. Defaults to 'text', but you may want to change it to other HTML5 values.
Generic implementation of setFromAny that implements exactly what the doc for setFromAny specifies, using a Manifest to check types
Generic implementation of setFromAny that implements exactly what the doc for setFromAny specifies, using a Manifest to check types
Should the field be ignored by the OR Mapper?
Should the field be ignored by the OR Mapper?
OptionalTypedField and MandatoryTypedField implement this to do the appropriate lifting of Box[MyType] to ValueType
OptionalTypedField and MandatoryTypedField implement this to do the appropriate lifting of Box[MyType] to ValueType
The text name of this field
The text name of this field
The error message used when the field value could not be set
The error message used when the field value could not be set
The error message used when the field value must be set
The error message used when the field value must be set
Is the value of this field optional (e.g.
Is the value of this field optional (e.g. NULLable)?
Return the owner of this field
Return the owner of this field
Helper function that does validation of a value by using the validators specified for the field
Helper function that does validation of a value by using the validators specified for the field
Are we in "safe" mode (i.e., the value of the field can be read or written without any security checks.)
Are we in "safe" mode (i.e., the value of the field can be read or written without any security checks.)
Set the value of the field to the given value.
Set the value of the field to the given value. Note: Because setting a field can fail (return non-Full), this method will return defaultValueBox if the field could not be set.
A list of functions that transform the value before it is set.
A list of functions that transform the value before it is set. The transformations are also applied before the value is used in a query. Typical applications of this are trimming and/or toLowerCase-ing strings
Set the value of the field from anything.
Set the value of the field from anything. Implementations of this method should accept at least the following (pattern => valueBox)
Note that setFromAny should _always_ call setBox, even if the conversion fails. This is so that validation properly notes the error.
The method genericSetFromAny implements this guideline.
Helper for implementing setFromJValue for a conversion from an encoded JString
Helper for implementing setFromJValue for a conversion from an encoded JString
function to try and transform a String into a field value
Decode the JValue and set the field to the decoded value.
Decode the JValue and set the field to the decoded value. Returns Empty or Failure if the value could not be set
Set the value of the field using some kind of type-specific conversion from a String.
Set the value of the field using some kind of type-specific conversion from a String. By convention, if the field is optional_?, then the empty string should be treated as no-value (Empty). Note that setFromString should _always_ call setBox, even if the conversion fails. This is so that validation properly notes the error.
Full(convertedValue) if the conversion succeeds (the field value will be set by side-effect) Empty or Failure if the conversion does not succeed
Generate a form control for the field
Generate a form control for the field
Convert the field value to an XHTML representation
Convert the field value to an XHTML representation
Validate this field's setting, returning any errors found
Validate this field's setting, returning any errors found