What is Packaging?
Packaging bundles up your application's executable files into a single file, called a distribution unit, so that it is easier to deploy and install your application to your user's computer.
With the Microsoft development environment you can package the files required to run your application (for example Java class files, Windows .exe or .dll files, HTML pages, and so on) into easily manageable and movable distribution units. Examples of packaging are:
Putting all the application files for an application into a single setup (.exe) file which, when run, installs the application and adds an item to the Windows Start menu.
- Putting all the Java .class and .gif files that implement an applet into a cabinet (.cab) file. Then, when an HTML page that references the applet is loaded, you can download and install the applet.
Create Three Types of Distribution Units
You can create three types of distribution units in the Microsoft development environment.
|Cabinet Packaging||Contains multiple files and is compressed to download and install components from Web pages (WFC components, applets, and so on).|
|Setup Packaging||Contains your application files and bundles them (in compressed form) into an executable file that installs the application on the user's computer. Includes an uninstaller program.|
|Zip Format Packaging||Contains multiple files in a single, uncompressed Zip Archive file format supported by many Web browsers.|
Two Methods of Creating Distribution Units
The Microsoft development environment helps you create these packaging types in two different ways:
Create in-place packaging by specifying the output format of any Visual J++ project to any of the three types (cabinet, setup, or Zip).
- Create a distribution unit project and add it to your solution. These distribution units can be of any of the three types (cabinet, setup, or Zip).
The advantage of in-place packaging is that you can easily create a cabinet, setup, or Zip file for your single Visual J++ project. The advantage of distribution units is that you can add as many distribution unit projects to your solution as you want, and each distribution unit can collect project outputs from multiple projects.