|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Archive<T extends Archive<T>>
Archive Represents a collection of resources which may be constructed declaratively / programmatically.
Method Summary | |
---|---|
T |
add(Archive<?> archive,
Path path)
Add an archive under a specific context and maintain the archive name as context path. |
T |
add(Asset asset,
Path target)
Adds the specified asset under the specified path into the target context |
T |
add(Asset asset,
Path target,
String name)
Adds the specified asset under the specified target (directory) using the specified name. |
T |
add(Asset asset,
String target)
Adds the specified resource under the context denoted by the specified target |
boolean |
contains(Path path)
Denotes whether this archive contains a resource at the specified path |
boolean |
delete(Path path)
Removes the asset in the archive at the specified Path. |
Asset |
get(Path path)
Obtains the asset located at the specified path |
Asset |
get(String path)
Obtains the asset located at the specified path |
Map<Path,Asset> |
getContent()
Obtains all assets in this archive, along with its respective Path. |
String |
getName()
Obtains the name of this archive (ie. myLibrary.jar) |
T |
merge(Archive<?> source)
Merge the contents from an existing archive without maintaining the archive name in the context path. |
T |
merge(Archive<?> source,
Path path)
Merge the contents from an existing archive in a specific path without maintaining the archive name in the context path. |
String |
toString(boolean verbose)
Returns a multiline "ls -l"-equse output of the contents of this deployment and (recursively) its children if the verbosity flag is set to "true". |
Methods inherited from interface org.jboss.shrinkwrap.api.Assignable |
---|
as |
Method Detail |
---|
String getName()
T add(Asset asset, Path target) throws IllegalArgumentException
target
- The context under which to add the assetsasset
-
IllegalArgumentException
- If no target or assets were specifiedT add(Asset asset, Path target, String name) throws IllegalArgumentException
target
- The context directory under which to add the assetname
- The name to assign the assent under the target namespaceasset
-
IllegalArgumentException
- If the target, name, or asset was not specifiedT add(Asset asset, String target) throws IllegalArgumentException
target
- asset
-
IllegalArgumentException
- If either the target or asset is not specifiedAsset get(Path path) throws IllegalArgumentException
path
-
IllegalArgumentException
- If the path is not specifiedAsset get(String path) throws IllegalArgumentException
path
-
IllegalArgumentException
- If the path is not specifiedboolean contains(Path path) throws IllegalArgumentException
path
-
IllegalArgumentException
- If the path is not specifiedboolean delete(Path path) throws IllegalArgumentException
path
-
IllegalArgumentException
Map<Path,Asset> getContent()
T add(Archive<?> archive, Path path) throws IllegalArgumentException
path
- to usearchive
- to add
IllegalArgumentException
- If the path or archive are not specifiedT merge(Archive<?> source) throws IllegalArgumentException
source
- Archive to add contents from
IllegalArgumentException
- If the existing archive is not specifiedT merge(Archive<?> source, Path path) throws IllegalArgumentException
source
- Archive to add contents frompath
- Path to add contents to
IllegalArgumentException
- If the path or existing archive is not specifiedString toString(boolean verbose)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |