public class GrailsByteArrayResource
extends ByteArrayResource
getURL()
method, required for the resource to work with Spring's
ServletContextResource.Constructor and Description |
---|
GrailsByteArrayResource(byte[] byteArray) |
GrailsByteArrayResource(byte[] byteArray,
java.lang.String location) |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getFilename() |
java.net.URL |
getURL()
Overrides the default behaviour to generate a fake "file:" URL
so that the resource can be used from a ServletContextResource.
|
public GrailsByteArrayResource(byte[] byteArray)
public GrailsByteArrayResource(byte[] byteArray, java.lang.String location)
public java.net.URL getURL() throws java.io.IOException
java.io.IOException
public java.lang.String getFilename() throws java.lang.IllegalStateException
java.lang.IllegalStateException