Microsoft SDK for Java

Packaging Samples

A Java package is a collection of classes that share a common namespace. Packages are easier to work with when they are encapsulated in a single file. The Microsoft SDK for Java provides tools for archiving packages in two formats (cabinet files and distribution units), and a package manager that can be used in conjunction with Microsoft® Internet Explorer to download and install packages. For more information on packaging, see Packaging and Distributing Software.

The following packaging samples are provided.

Sample Description
AFC Detect Location: \Samples\afc11\AFCDetect

Technologies: AFC, packaging

Demonstrates:

  • Using the com.ms.util.SystemVersionManager class to retrieve package version information and take appropriate actions (such as installing new package versions). The sample determines whether AFC is installed on a computer and which version is installed.
Cabinet File Creation Location: \Samples\Packaging\Create

Technologies: Packaging

Demonstrates:

  • Using the CabCreator class in com.ms.util.cab to create cabinet files.
Cabinet File Extraction Location: \Samples\Packaging\Extract

Technologies: Packaging

Demonstrates:

  • Using the cabinet decoder classes in com.ms.util.cab to extract files from cabinets.
Java Package Manager Location: \Samples\Packaging\Pkgmgmt

Technologies: Packaging, Java Package Manager (JPM), HTML scripting, security

Demonstrates:

  • Building cabinet files using the Microsoft SDK for Java.

  • Signing cabinet files for use in a Web browser.

  • Generating certificates for signing cabinet files using tools provided by the Microsoft SDK for Java.

  • Using HTML script to run an applet that installs classes into the local computer's package manager.

  • Using JPM to install applications, class libraries, and applets.
Jexegen Location: \Samples\Native\Jexegen

Technologies:Native code, packaging

Demonstrates:

  • Packaging Java applications as executables using the jexegen tool.

  • Attaching an arbitrary native stub to a Java application to create stand-alone executables.

  • Starting the Microsoft VM using C code and running an arbitrary Java application.
Win32 Resource Loading Location: \Samples\Windows\Win32ResSupport

Technologies: Windows, AFC, internationalization, packaging

Demonstrates:

  • Using the supported Microsoft® Win32® resource styles and controls included with the Win32ResourceDecoder class in the com.ms.ui.resource package.

  • Using Win32 resource (.res) files to develop multilingual applications.

  • Using the resmerge tool to combine multiple Win32 resource files into a single file.

© 1999 Microsoft Corporation. All rights reserved. Terms of use.