EasyManua.ls Logo

MACROMEDIA FLASH 8-USING FLASH - Page 442

MACROMEDIA FLASH 8-USING FLASH
678 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
442 Data Integration (Flash Professional Only)
Schema data types
A data type is an object that represents all the runtime logic needed to support a particular
data type. A data type can be a scalar type, such as integer, string, date, currency amount, or
ZIP code. It can also be a complex type, with subfields and so on. A data type can test a data
value to determine if it is valid for that data type. The following data types come with Flash
MX Professional 2004 and Flash Professional 8:
Array No validation options.
Attribute XML attribute. No validation options.
Boolean No validation options.
Custom Lets you add a custom class to check for this special kind of validation. Your code
should call the validate function when the field is assigned a new value, inspect the value, and
determine whether its valid. If it is, the function should simply return. If not, the function
should call
this.ValidationError(“some informative message”);. The custom class
must be in the classpath and formatted as shown in the following example:
class myCustomType extends mx.databinding.CustomValidator {
function validate(value) {
... some code here
}
}
DataProvider
No validation options.
Date No validation options.
DeltaPacket No validation options.
Integer A validation option can be set up to define the minimum and maximum values.
Number A validation option can be set up to define the minimum and maximum values.
Object No validation options.
PhoneNumber No validation options.
SocialSecurity No validation options.
String A validation option can be set up to define the minimum and maximum number of
characters.
XML Lets you specify if white space should be ignored when a string is converted into
XML.
ZipCode No validation options.
NOTE
The following data types can perform validation: Custom, Integer, Number,
PhoneNumber, SocialSecurity, String, ZipCode. The following data types can convert
from various other data types when you assign to them: Boolean, DataProvider, Integer,
Number, String, XML.

Table of Contents

Related product manuals