类 TransformedResource
- java.lang.Object
- org.springframework.core.io.AbstractResource
- org.springframework.core.io.ByteArrayResource
- org.springframework.web.reactive.resource.TransformedResource
- 所有已实现的接口:
InputStreamSource,Resource
public class TransformedResource extends ByteArrayResource
An extension ofByteArrayResourcethat aResourceTransformercan use to represent an original resource preserving all other information except the content.- 从以下版本开始:
- 5.0
- 作者:
- Rossen Stoyanchev
构造器概要
构造器 构造器 说明 TransformedResource(Resource original, byte[] transformedContent)
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 StringgetFilename()This implementation always returnsnull, assuming that this resource type does not have a filename.longlastModified()This implementation checks the timestamp of the underlying File, if available.从类继承的方法 org.springframework.core.io.ByteArrayResource
contentLength, equals, exists, getByteArray, getDescription, getInputStream, hashCode
从类继承的方法 org.springframework.core.io.AbstractResource
createRelative, getFile, getFileForLastModifiedCheck, getURI, getURL, isFile, isOpen, isReadable, readableChannel, toString
构造器详细资料
TransformedResource
public TransformedResource(Resource original, byte[] transformedContent)
方法详细资料
getFilename
@Nullable public String getFilename()
从类复制的说明:AbstractResourceThis implementation always returnsnull, assuming that this resource type does not have a filename.- 指定者:
getFilename在接口中Resource- 覆盖:
getFilename在类中AbstractResource
lastModified
public long lastModified()
从类复制的说明:AbstractResourceThis implementation checks the timestamp of the underlying File, if available.