All Packages Class Hierarchy This Package Previous Next Index
Class com.sun.wizards.builder.FileResourceWriter
java.lang.Object
|
+----com.sun.wizards.builder.FileResourceWriter
- public class FileResourceWriter
- extends Object
- implements ResourceWriter
Note: FileResourceWriter is deprecated.
In order to follow the common stream format, Objects do not write their own data to the Archive. Rather,
you should create a ResourceCollection specifying the resources that your ResourceWriter object will write, and create
a ResourceResolver that knows how to find those classes. Then register the ResourceResolver with the ResourceCollection,
and the ResourceCollection with the ArchiveCreator. Then the ArchiveCreator will call upon your ResourceResolver and
place the resolved resources into the WizardArchive.
To convert A FileResourceWriter (or subclass of), simply Create a ResourceCollection that is configured with the same
files as the FileResourceWriter would write. Then configure a FileResolver with a path that will get all of the
files, and register the ResourceCollection with your ArchiveCreator.
This object creates an archive resource containing files.
The files are specified through the addFile method.
In order for this ResourceWriter to write the files
into the wizard archive, this object must be registered
into the ArchiveWriter via the addResource method.
-
FileResourceWriter(String)
- Creates a FileResourceWriter that will write the specified
resource into the wizard archive.
-
addFile(String)
- Adds the specified file or directory to the resource.
-
writeResource(DataOutput)
- This method writes the registered files into the specified output stream.
FileResourceWriter
public FileResourceWriter(String resourceName)
- Creates a FileResourceWriter that will write the specified
resource into the wizard archive.
- Parameters:
- resourceName - The name of the wizard resource this object will write.
addFile
public void addFile(String path)
- Adds the specified file or directory to the resource.
- Parameters:
- path - The path to the file or directory.
writeResource
public void writeResource(DataOutput out)
- This method writes the registered files into the specified output stream.
- Parameters:
- out - The output stream to write the registered files into.
All Packages Class Hierarchy This Package Previous Next Index