Schema encoders (Flash Professional only)

An encoder determines how a schema item for your component should be encoded/decoded at runtime. The number of encoders allowed is unlimited, and you can create additional custom encoders/decoders. Encoders are defined by XML files found in the Flash MX Professional 2004 Configuration/Encoders folder. The definition includes the following metadata:

The following encoders ship with Flash MX Professional 2004:

None The default encoder. No encoding/decoding is performed.

Boolean Converts string data into Boolean ActionScript types. You must specify (via the Encoder Options property) one or more strings that will be interpreted as true, and one or more strings that will be interpreted as false. The settings are case-sensitive.

Date Converts string data into date ActionScript types. You must specify (via the Encoder Options property) a template string, which works as follows:

DateToNumber Converts a Date object into its numeric equivalent. The DataSet component uses this encoder for fields that are of type Date. These values are stored within the DataSet component as numbers so that they can be sorted correctly.

Number Converts string data into number ActionScript types. There are no authoring settings for this encoder.

DatasetDeltaToXUpdateDelta This encoder is used in conjunction with the DataSet component. It extracts information from a DeltaPacket and generates XPath statements that are passed to the XUpdateResolver component to generate XUpdate statements. It gets the information that is needs to generate the XPath statements from two places:

Using this information, the encoder can generate the correct XPath statements needed to identify your data within the XML file.

The encoder options contain one property: