|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jboss.shrinkwrap.api.asset.ByteArrayAsset
public class ByteArrayAsset

Implementation of an Asset backed by a byte array
| Constructor Summary | |
|---|---|
ByteArrayAsset(byte[] content)
Creates a new Asset instance backed by the specified
byte array |
|
ByteArrayAsset(InputStream stream)
Creates a new Asset instance backed by the bytes
contained in the the specified InputStream |
|
| Method Summary | |
|---|---|
InputStream |
openStream()
Get a input stream for the resource content. |
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public ByteArrayAsset(byte[] content)
throws IllegalArgumentException
Asset instance backed by the specified
byte array
content -
IllegalArgumentException - If the contents were not specifiedpublic ByteArrayAsset(InputStream stream)
Asset instance backed by the bytes
contained in the the specified InputStream
stream -
IllegalArgumentException - If the stream is not specified| Method Detail |
|---|
public InputStream openStream()
AssetAsset
is to be viewed as a logical path (placeholder/directory)
only with no backing content.
openStream in interface AssetInputStream for each call, or null if this
type simply represents a logical path within an ArchiveAsset.openStream()public String toString()
toString in class ObjectObject.toString()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||