public class TransformedResource extends ByteArrayResource
ByteArrayResource
that a ResourceTransformer
can use to represent an original resource preserving all other information
except the content.Constructor and Description |
---|
TransformedResource(Resource original,
byte[] transformedContent) |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getFilename()
This implementation always returns
null ,
assuming that this resource type does not have a filename. |
long |
lastModified()
This implementation checks the timestamp of the underlying File,
if available.
|
contentLength, equals, exists, getByteArray, getDescription, getInputStream, hashCode
createRelative, getFile, getFileForLastModifiedCheck, getURI, getURL, isFile, isOpen, isReadable, readableChannel, toString
public TransformedResource(Resource original, byte[] transformedContent)
@Nullable public java.lang.String getFilename()
AbstractResource
null
,
assuming that this resource type does not have a filename.getFilename
in interface Resource
getFilename
in class AbstractResource
public long lastModified()
AbstractResource
lastModified
in interface Resource
lastModified
in class AbstractResource
AbstractResource.getFileForLastModifiedCheck()