|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface ResourceContainer<T extends Archive<T>>

Defines the contract for a component capable of storing
a series of ClassLoader, File, and URL-based
Assets as resources within an archive.
The actual path to the Resources within the Archive
is up to the implementations/specifications.
| Method Summary | |
|---|---|
T |
addResource(Asset resource,
ArchivePath target)
Adds the Asset as a resource to the container, returning the container itself. |
T |
addResource(Asset resource,
String target)
Adds the Asset as a resource to the container, returning the container itself. |
T |
addResource(File resource)
Adds the File as a resource to the container, returning the container itself. |
T |
addResource(File resource,
ArchivePath target)
Adds the File as a resource to the container, returning the container itself. |
T |
addResource(File resource,
String target)
Adds the File as a resource to the container, returning the container itself. |
T |
addResource(Package resourcePackage,
String resourceName)
Adds the resource as a resource to the container, returning the container itself. |
T |
addResource(Package resourcePackage,
String resourceName,
ArchivePath target)
Adds the resource as a resource to a specific path inside the container, returning the container itself. |
T |
addResource(Package resourcePackage,
String resourceName,
String target)
Adds the resource as a resource to a specific path inside the container, returning the container itself. |
T |
addResource(String resourceName)
Adds the resource as a resource to the container, returning the container itself. |
T |
addResource(String resourceName,
ArchivePath target)
Adds the resource with the specified name to the container, returning the container itself. |
T |
addResource(String resourceName,
ArchivePath target,
ClassLoader classLoader)
Adds the resource as a resource to the container, returning the container itself. |
T |
addResource(String resourceName,
String target)
Adds the resource as a resource to the container, returning the container itself. |
T |
addResource(URL resource,
ArchivePath target)
Adds the URL as a resource to the container, returning the container itself. |
T |
addResource(URL resource,
String target)
Adds the URL as a resource to the container, returning the container itself. |
T |
addResources(Package resourcePackage,
String... resourceNames)
Adds the resources inside the package as multiple resources to the container, returning the container itself. |
| Method Detail |
|---|
T addResource(String resourceName)
throws IllegalArgumentException
ClassLoader used to obtain the resource is up to the implementation.
resourceName - resource to add
IllegalArgumentException - If the resourceName is nulladdResource(Asset, ArchivePath)
T addResource(File resource)
throws IllegalArgumentException
File as a resource to the container, returning the container itself.
File will be placed into the Container Library path under File.getName().
resource - File resource to add
IllegalArgumentException - If the resource is nulladdResource(Asset, ArchivePath)
T addResource(String resourceName,
String target)
throws IllegalArgumentException
ClassLoader used to obtain the resource is up to the implementation.
resourceName - resource to addtarget - The target path within the archive in which to add the resource, relative to the Archives resource path.
IllegalArgumentException - if resourceName is null
IllegalArgumentException - if target is nulladdResource(Asset, ArchivePath)
T addResource(File resource,
String target)
throws IllegalArgumentException
File as a resource to the container, returning the container itself.
resource - File resource to addtarget - The target path within the archive in which to add the resource, relative to the Archives resource path.
IllegalArgumentException - if resource is null
IllegalArgumentException - if target is nulladdResource(Asset, ArchivePath)
T addResource(URL resource,
String target)
throws IllegalArgumentException
URL as a resource to the container, returning the container itself.
resource - URL resource to addtarget - The target path within the archive in which to add the resource, relative to the Archives resource path.
IllegalArgumentException - if resource is null
IllegalArgumentException - if target is nulladdResource(Asset, ArchivePath)
T addResource(Asset resource,
String target)
throws IllegalArgumentException
Asset as a resource to the container, returning the container itself.
resource - Asset resource to addtarget - The target path within the archive in which to add the resource, relative to the Archives resource path.
IllegalArgumentException - if resource is null
IllegalArgumentException - if target is nulladdResource(Asset, ArchivePath)
T addResource(String resourceName,
ArchivePath target)
throws IllegalArgumentException
ClassLoader used to obtain the resource is up to the implementation.
target - The target within the archive into which we'll place the resourceresourceName - Name of the ClassLoader resource to add
IllegalArgumentException - If the target is null
IllegalArgumentException - If the resourceName is null
T addResource(String resourceName,
ArchivePath target,
ClassLoader classLoader)
throws IllegalArgumentException
ClassLoader used to obtain the resource is up to the implementation.
resourceName - resource to addtarget - The target path within the archive in which to add the resource, relative to the Archives resource path.
IllegalArgumentException - if resourceName is null
IllegalArgumentException - if target is nulladdResource(Asset, ArchivePath)
T addResource(File resource,
ArchivePath target)
throws IllegalArgumentException
File as a resource to the container, returning the container itself.
resource - File resource to addtarget - The target path within the archive in which to add the resource, relative to the Archives resource path.
IllegalArgumentException - if resource is null
IllegalArgumentException - if target is nulladdResource(Asset, ArchivePath)
T addResource(URL resource,
ArchivePath target)
throws IllegalArgumentException
URL as a resource to the container, returning the container itself.
resource - URL resource to addtarget - The target path within the archive in which to add the resource, relative to the Archives resource path.
IllegalArgumentException - if resource is null
IllegalArgumentException - if target is nulladdResource(Asset, ArchivePath)
T addResource(Asset resource,
ArchivePath target)
throws IllegalArgumentException
Asset as a resource to the container, returning the container itself.
resource - Asset resource to addtarget - The target path within the archive in which to add the resource, relative to the Archives resource path.
IllegalArgumentException - if resource is null
IllegalArgumentException - if target is null
T addResources(Package resourcePackage,
String... resourceNames)
throws IllegalArgumentException
ClassLoader used to obtain the resource is up to the implementation.
resourcePackage - The package of the resourcesresourceNames - The names of the resources inside resoucePackage
IllegalArgumentException - if resourcePackage is null
IllegalArgumentException - if no resourceNames are specified or containing null
T addResource(Package resourcePackage,
String resourceName)
throws IllegalArgumentException
ClassLoader used to obtain the resource is up to the implementation.
resourcePackage - The package of the resourceresourceName - The name of the resource inside resoucePackage
IllegalArgumentException - if resourcePackage is null
IllegalArgumentException - if resourceName is null
T addResource(Package resourcePackage,
String resourceName,
String target)
throws IllegalArgumentException
ClassLoader used to obtain the resource is up to the implementation.
resourcePackage - The package of the resourceresourceName - The name of the resource inside resoucePackagetarget - The target location inside the container
IllegalArgumentException - if resourcePackage is null
IllegalArgumentException - if resourceName is null
IllegalArgumentException - if target is null
T addResource(Package resourcePackage,
String resourceName,
ArchivePath target)
throws IllegalArgumentException
ClassLoader used to obtain the resource is up to the implementation.
resourcePackage - The package of the resourceresourceName - The name of the resource inside resoucePackagetarget - The target location inside the container
IllegalArgumentException - if resourcePackage is null
IllegalArgumentException - if resourceName is null
IllegalArgumentException - if target is null
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||