Class FileSystemDeletableResource

java.lang.Object
internal.org.springframework.content.fs.io.FileSystemDeletableResource
All Implemented Interfaces:
DeletableResource, IdentifiableResource, org.springframework.core.io.InputStreamSource, org.springframework.core.io.Resource, org.springframework.core.io.WritableResource

public class FileSystemDeletableResource extends Object implements org.springframework.core.io.WritableResource, DeletableResource, IdentifiableResource
  • Constructor Details

    • FileSystemDeletableResource

      public FileSystemDeletableResource(org.springframework.core.io.FileSystemResource resource, FileService fileService)
  • Method Details

    • delete

      public void delete()
      Specified by:
      delete in interface DeletableResource
    • isOpen

      public boolean isOpen()
      Specified by:
      isOpen in interface org.springframework.core.io.Resource
    • getPath

      public final String getPath()
    • exists

      public boolean exists()
      Specified by:
      exists in interface org.springframework.core.io.Resource
    • isReadable

      public boolean isReadable()
      Specified by:
      isReadable in interface org.springframework.core.io.Resource
    • getInputStream

      public InputStream getInputStream() throws IOException
      Specified by:
      getInputStream in interface org.springframework.core.io.InputStreamSource
      Throws:
      IOException
    • isWritable

      public boolean isWritable()
      Specified by:
      isWritable in interface org.springframework.core.io.WritableResource
    • lastModified

      public long lastModified() throws IOException
      Specified by:
      lastModified in interface org.springframework.core.io.Resource
      Throws:
      IOException
    • getOutputStream

      public OutputStream getOutputStream() throws IOException
      Specified by:
      getOutputStream in interface org.springframework.core.io.WritableResource
      Throws:
      IOException
    • getURL

      public URL getURL() throws IOException
      Specified by:
      getURL in interface org.springframework.core.io.Resource
      Throws:
      IOException
    • getURI

      public URI getURI() throws IOException
      Specified by:
      getURI in interface org.springframework.core.io.Resource
      Throws:
      IOException
    • getFile

      public File getFile()
      Specified by:
      getFile in interface org.springframework.core.io.Resource
    • contentLength

      public long contentLength() throws IOException
      Specified by:
      contentLength in interface org.springframework.core.io.Resource
      Throws:
      IOException
    • createRelative

      public org.springframework.core.io.Resource createRelative(String relativePath)
      Specified by:
      createRelative in interface org.springframework.core.io.Resource
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • getFilename

      public String getFilename()
      Specified by:
      getFilename in interface org.springframework.core.io.Resource
    • getDescription

      public String getDescription()
      Specified by:
      getDescription in interface org.springframework.core.io.Resource
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • getId

      public Serializable getId()
      Specified by:
      getId in interface IdentifiableResource
    • setId

      public void setId(Serializable id)
      Specified by:
      setId in interface IdentifiableResource