Class ResourceBasedRemoteFile

  • All Implemented Interfaces:
    RemoteFile

    public class ResourceBasedRemoteFile
    extends Object
    implements RemoteFile
    Implementation of RemoteFile that basically is facade to a Spring Resource.
    Author:
    avasquez
    • Constructor Detail

      • ResourceBasedRemoteFile

        public ResourceBasedRemoteFile​(RemotePath path,
                                       org.springframework.core.io.Resource resource)
    • Method Detail

      • getPath

        public RemotePath getPath()
        Description copied from interface: RemoteFile
        Returns information about the path of the file in the remote store.
        Specified by:
        getPath in interface RemoteFile
      • toResource

        public org.springframework.core.io.Resource toResource()
                                                        throws IOException
        Description copied from interface: RemoteFile
        Returns the remote file as a Spring Resource.
        Specified by:
        toResource in interface RemoteFile
        Throws:
        IOException - if the file can't be resolved successfully as a resource