Saving a palette on the file system can be done through
the palette manager. The palette manager first saves the palette hierarchy
in a working directory and then packages the working directory into
a .jar file.
-
Specify the working directory:
myIlvPaletteManager.setWorkingDirectory(new File("/tmp"));
-
Save the palette in the current directory:
myIlvPaletteManager.save(palette, new File("myPalette.jar"));
When a palette is saved, symbol resources, such as images
which were imported from outside the palette .jar file are copied
into it. Links to these resources are updated accordingly. Therefore,
the resulting file myPalette.jar
is self-contained,
that is, it does no longer contain any reference to external files.