Macromedia flex 2 Manual

Página de 254
About compiling
65
The default option is the target file to compile into a SWF file, and it is required to have a 
value. If you use a space-separated list as part of the options, you can terminate the list with a 
double hyphen before adding the target file; for example:
$ mxmlc -option arg1 arg2 arg3 -- target_file.mxml
About compiling with Flex Data Services
If you have Adobe Flex Data Services, you can use mxmlc to compile your application when 
an HTTP request occurs. To do so, you deploy your application as MXML, ActionScript, 
SWC, and RSL files under the web root directory of your application server. When a user 
requests the main MXML file, the request triggers the compilation.
A request to an MXML file has the following form:
http://hostname/path/filename.mxml
When Flex Data Services receives an HTTP request for an MXML file, Flex Data Services 
performs the following steps:
1.
Compiles the MXML file to produce a SWF file.
2.
Caches the compiled SWF file on the server.
3.
Returns the SWF file to the client. 
About case sensitivity during a compilation
The Flex compilers use a case-sensitive file lookup on all file systems. On case-insensitive file 
systems, such as the Macintosh and Windows file systems, the Flex compiler generates a case-
mismatch error when you use a component with the incorrect case. On case-sensitive file 
systems, such as the UNIX file system, the Flex compiler generates a component-not-found 
error when you use a component with the incorrect case. 
About the ActionScript classpath
Typically, you put component files in directories that are in the ActionScript classpath. These 
include your application’s root directory, its subdirectories, and any directory that you specify 
to the compiler. To specify a directory, you use the 
source-path
 option to the mxmlc 
compiler, or the Project Properties dialog box in Flex Builder. 
The following rules can help you organize your custom components:
An application can access MXML and ActionScript components in the same directory, 
and in its subdirectories.