If you plan to use this method keep in mind that someone thought it was a good idea to send an additional zero (0) byte after your data.
Converts the XML object or data specified in the object parameter to a string and transmits it to the server, followed by a zero (0) byte.
Making swc files with ant
If you want to make a swc you need to use the compc flex ant task. However the include-classes attribute requires you to write each and every one of the classes that you want to include in your swc. Quite tedious and not maintainable at all. Luckily you can use this converting file list into a class list code if you can live with the convention that the classes are named the same as the files they are in.