Top Description Constructors Methods
org.codehaus.commons.compiler.util.resource

public abstract Class FileResourceCreator

extends Object
implements ResourceCreator
Class Inheritance
All Implemented Interfaces
org.codehaus.commons.compiler.util.resource.ResourceCreator
Known Direct Subclasses
org.codehaus.commons.compiler.util.resource.DirectoryResourceCreator
Imports
java.io.File, .FileOutputStream, .IOException, .OutputStream

Stores a stream of bytes in a named resource.

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public final OutputStream
createResource(String
Designates the resource; typically structured by slashes ("/") like "com/foo/pkg/Bar.class"
resourceName
)

Implements org.codehaus.commons.compiler.util.resource.ResourceCreator.createResource.

Creates the designated resource.
public final boolean
deleteResource(String resourceName)

Implements org.codehaus.commons.compiler.util.resource.ResourceCreator.deleteResource.

Deletes the resource with the given name.
protected abstract File

Returns:

The file into which the contents is written
getFile
(String resourceName)

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

FileResourceCreatorback to summary
public FileResourceCreator()

Method Detail

createResourceback to summary
public final OutputStream createResource(String resourceName) throws IOException

Implements org.codehaus.commons.compiler.util.resource.ResourceCreator.createResource.

Doc from org.codehaus.commons.compiler.util.resource.ResourceCreator.createResource.

Creates the designated resource.

Parameters
resourceName:String

Designates the resource; typically structured by slashes ("/") like "com/foo/pkg/Bar.class"

Returns:OutputStream

Bytes written to this OutputStream are stored in the resource

Annotations
@Override
Exceptions
IOException:
Problems creating the resource
deleteResourceback to summary
public final boolean deleteResource(String resourceName)

Implements org.codehaus.commons.compiler.util.resource.ResourceCreator.deleteResource.

Doc from org.codehaus.commons.compiler.util.resource.ResourceCreator.deleteResource.

Deletes the resource with the given name.

Returns:boolean

false if the resource could not be deleted

Annotations
@Override
getFileback to summary
protected abstract File getFile(String resourceName)
Returns:File

The file into which the contents is written