public class ByteArrayResource extends AbstractResource
| Constructor and Description |
|---|
ByteArrayResource(String mimetype,
byte[] bytes)
Creates a new ByteArrayResource which provides access to the given byte
array.
|
| Modifier and Type | Method and Description |
|---|---|
InputStream |
asStream()
Returns an InputStream which reads the contents of this resource,
starting with the first byte.
|
getLastModified, getMimeTypepublic ByteArrayResource(String mimetype, byte[] bytes)
mimetype - The mimetype of the resource.bytes - The bytes that this resource should contain.public InputStream asStream()
ResourceCopyright © 2015. All rights reserved.