PackageDescription: FileOut30
File Out 3 0Last published: July 20, 2009 by 'sames'
Defines 18 Classes
Extends 36 Classes
This goodie provides the ability to load and save code in a variety of formats other than the standard VisualWorks XML and Chunk formats. Most notably, it provides compatibility with VisualWorks 3.0 file-out format, but it can also be used to load and save code for various other Smalltalk dialects.
File-in formats should automatically be recognized. To set a file-out format, see the Source tab in the VisualWorks settings.
The "VW3.0 compatible source code" setting will create file-outs compatible with VisualWorks 3.0. Note that if you save a parcel with this 3.0 File-Out option set, that parcel will have its source also saved in VisualWorks 3.0 format.
The remaining formats are provided as part of the FileOut30 goodie for compatibility with other dialects, are not fully supported, lack documentation, and quite possibly have problems. These formats allow you to read or write package formats from some other dialects with as much information as possible preserved between them. For all of these formats there are some conventions observed.
- A prerequisite of the form Port will be transformed appropriately on file-in or file-out, where dialect is one of VW, VA, or Dolphin. So, for example, FooVWPort would become FooDolphinPort if filed out in Dolphin format.
- On file-in, at least some properties are preserved. The most notable example is ENVY prerequisites. On file-in of an ENVY application, any prerequisites whose names did not correspond to packages in the image are preserved in the envyPrerequisites variable and will be added back into the prerequisite list on file-out in ENVY format.
- Note that these formats do not ensure valid syntax in the target dialect. For example, an ENVY application cannot have whitespace in its name, and a hyphen in a Dolphin method category indicates a hierarchical category. The system will attempt to compensate for some of these known differences, but in general you are responsible for writing portable code.
- These have been tested primarily for reading/writing complete packages/applications. Use for code fragments (e.g. differences between packages) may or may not work properly.
VisualAge-compatible format is a format which can read and write VisualAge .app format files. This is primarily intended for filing out a complete Store package into a VisualAge application. Namespace information will be removed, and as much package information as possible will be preserved. This format is tested against current versions of VisualAge, but should also work with little or no modification for older versions and for VisualWorks/ENVY code. It is also possible to file out a complete bundle with this format and get a single file which can recreate all of the component packages as applications. Note that this does not at the moment attempt to create configuration maps or version the resulting code.
Dolphin 4.0-compatible format is a format which is compatible with the .pac files of Dolphin Smalltalk. These files should be directly loadable into a Dolphin image as packages.
Squeak format is a format roughly compatible with Squeak file-out format. Note that it doesn't attempt to handle dialect differences such as the conversion between underscore/left arrow and :=. This support was contributed by Roel Wuyts.