public class DefaultScpFileOpener extends AbstractLoggingBean implements ScpFileOpener
| Modifier and Type | Field and Description |
|---|---|
static DefaultScpFileOpener |
INSTANCE |
log| Constructor and Description |
|---|
DefaultScpFileOpener() |
| Modifier and Type | Method and Description |
|---|---|
ScpSourceStreamResolver |
createScpSourceStreamResolver(Session session,
java.nio.file.Path path) |
ScpTargetStreamResolver |
createScpTargetStreamResolver(Session session,
java.nio.file.Path path) |
java.io.InputStream |
openRead(Session session,
java.nio.file.Path file,
long size,
java.util.Set<java.nio.file.attribute.PosixFilePermission> permissions,
java.nio.file.OpenOption... options)
Create an input stream to read from a file
|
java.io.OutputStream |
openWrite(Session session,
java.nio.file.Path file,
long size,
java.util.Set<java.nio.file.attribute.PosixFilePermission> permissions,
java.nio.file.OpenOption... options)
Create an output stream to write to a file
|
getSimplifiedLoggerclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetLocalBasicFileAttributes, getLocalFilePermissions, getLocalFolderChildren, getMatchingFilesToSend, resolveIncomingFilePath, resolveIncomingReceiveLocation, resolveLocalPath, resolveOutgoingFilePath, sendAsDirectory, sendAsRegularFile, updateFilePropertiespublic static final DefaultScpFileOpener INSTANCE
public java.io.InputStream openRead(Session session, java.nio.file.Path file, long size, java.util.Set<java.nio.file.attribute.PosixFilePermission> permissions, java.nio.file.OpenOption... options) throws java.io.IOException
ScpFileOpeneropenRead in interface ScpFileOpenersession - The Session requesting the accessfile - The requested local file Pathsize - The expected transfer bytes countpermissions - The requested file permissionsoptions - The OpenOptions - may be null/emptyInputStream never nulljava.io.IOException - If failed to open the filepublic java.io.OutputStream openWrite(Session session, java.nio.file.Path file, long size, java.util.Set<java.nio.file.attribute.PosixFilePermission> permissions, java.nio.file.OpenOption... options) throws java.io.IOException
ScpFileOpeneropenWrite in interface ScpFileOpenersession - The Session requesting the accessfile - The requested local file Pathsize - The expected transfer byte countpermissions - The requested file permissionsoptions - The OpenOptions - may be null/emptyOutputStream never nulljava.io.IOException - If failed to open the filepublic ScpSourceStreamResolver createScpSourceStreamResolver(Session session, java.nio.file.Path path) throws java.io.IOException
createScpSourceStreamResolver in interface ScpFileOpenerjava.io.IOExceptionpublic ScpTargetStreamResolver createScpTargetStreamResolver(Session session, java.nio.file.Path path) throws java.io.IOException
createScpTargetStreamResolver in interface ScpFileOpenerjava.io.IOException