Class ScpOperations

  • All Implemented Interfaces:
    org.apache.camel.component.file.GenericFileOperations<ScpFile>, org.apache.camel.component.file.remote.RemoteFileOperations<ScpFile>

    public class ScpOperations
    extends Object
    implements org.apache.camel.component.file.remote.RemoteFileOperations<ScpFile>
    SCP remote file operations
    • Constructor Detail

      • ScpOperations

        public ScpOperations()
    • Method Detail

      • newGenericFile

        public org.apache.camel.component.file.GenericFile<ScpFile> newGenericFile()
        Specified by:
        newGenericFile in interface org.apache.camel.component.file.GenericFileOperations<ScpFile>
      • setEndpoint

        public void setEndpoint​(org.apache.camel.component.file.GenericFileEndpoint<ScpFile> endpoint)
        Specified by:
        setEndpoint in interface org.apache.camel.component.file.GenericFileOperations<ScpFile>
      • deleteFile

        public boolean deleteFile​(String name)
                           throws org.apache.camel.component.file.GenericFileOperationFailedException
        Specified by:
        deleteFile in interface org.apache.camel.component.file.GenericFileOperations<ScpFile>
        Throws:
        org.apache.camel.component.file.GenericFileOperationFailedException
      • existsFile

        public boolean existsFile​(String name)
                           throws org.apache.camel.component.file.GenericFileOperationFailedException
        Specified by:
        existsFile in interface org.apache.camel.component.file.GenericFileOperations<ScpFile>
        Throws:
        org.apache.camel.component.file.GenericFileOperationFailedException
      • renameFile

        public boolean renameFile​(String from,
                                  String to)
                           throws org.apache.camel.component.file.GenericFileOperationFailedException
        Specified by:
        renameFile in interface org.apache.camel.component.file.GenericFileOperations<ScpFile>
        Throws:
        org.apache.camel.component.file.GenericFileOperationFailedException
      • buildDirectory

        public boolean buildDirectory​(String directory,
                                      boolean absolute)
                               throws org.apache.camel.component.file.GenericFileOperationFailedException
        Specified by:
        buildDirectory in interface org.apache.camel.component.file.GenericFileOperations<ScpFile>
        Throws:
        org.apache.camel.component.file.GenericFileOperationFailedException
      • retrieveFile

        public boolean retrieveFile​(String name,
                                    org.apache.camel.Exchange exchange,
                                    long isze)
                             throws org.apache.camel.component.file.GenericFileOperationFailedException
        Specified by:
        retrieveFile in interface org.apache.camel.component.file.GenericFileOperations<ScpFile>
        Throws:
        org.apache.camel.component.file.GenericFileOperationFailedException
      • releaseRetrievedFileResources

        public void releaseRetrievedFileResources​(org.apache.camel.Exchange exchange)
                                           throws org.apache.camel.component.file.GenericFileOperationFailedException
        Specified by:
        releaseRetrievedFileResources in interface org.apache.camel.component.file.GenericFileOperations<ScpFile>
        Throws:
        org.apache.camel.component.file.GenericFileOperationFailedException
      • storeFile

        public boolean storeFile​(String name,
                                 org.apache.camel.Exchange exchange,
                                 long size)
                          throws org.apache.camel.component.file.GenericFileOperationFailedException
        Specified by:
        storeFile in interface org.apache.camel.component.file.GenericFileOperations<ScpFile>
        Throws:
        org.apache.camel.component.file.GenericFileOperationFailedException
      • getCurrentDirectory

        public String getCurrentDirectory()
                                   throws org.apache.camel.component.file.GenericFileOperationFailedException
        Specified by:
        getCurrentDirectory in interface org.apache.camel.component.file.GenericFileOperations<ScpFile>
        Throws:
        org.apache.camel.component.file.GenericFileOperationFailedException
      • changeCurrentDirectory

        public void changeCurrentDirectory​(String path)
                                    throws org.apache.camel.component.file.GenericFileOperationFailedException
        Specified by:
        changeCurrentDirectory in interface org.apache.camel.component.file.GenericFileOperations<ScpFile>
        Throws:
        org.apache.camel.component.file.GenericFileOperationFailedException
      • changeToParentDirectory

        public void changeToParentDirectory()
                                     throws org.apache.camel.component.file.GenericFileOperationFailedException
        Specified by:
        changeToParentDirectory in interface org.apache.camel.component.file.GenericFileOperations<ScpFile>
        Throws:
        org.apache.camel.component.file.GenericFileOperationFailedException
      • listFiles

        public List<ScpFile> listFiles()
                                throws org.apache.camel.component.file.GenericFileOperationFailedException
        Specified by:
        listFiles in interface org.apache.camel.component.file.GenericFileOperations<ScpFile>
        Throws:
        org.apache.camel.component.file.GenericFileOperationFailedException
      • listFiles

        public List<ScpFile> listFiles​(String path)
                                throws org.apache.camel.component.file.GenericFileOperationFailedException
        Specified by:
        listFiles in interface org.apache.camel.component.file.GenericFileOperations<ScpFile>
        Throws:
        org.apache.camel.component.file.GenericFileOperationFailedException
      • connect

        public boolean connect​(org.apache.camel.component.file.remote.RemoteFileConfiguration configuration,
                               org.apache.camel.Exchange exchange)
                        throws org.apache.camel.component.file.GenericFileOperationFailedException
        Specified by:
        connect in interface org.apache.camel.component.file.remote.RemoteFileOperations<ScpFile>
        Throws:
        org.apache.camel.component.file.GenericFileOperationFailedException
      • isConnected

        public boolean isConnected()
                            throws org.apache.camel.component.file.GenericFileOperationFailedException
        Specified by:
        isConnected in interface org.apache.camel.component.file.remote.RemoteFileOperations<ScpFile>
        Throws:
        org.apache.camel.component.file.GenericFileOperationFailedException
      • disconnect

        public void disconnect()
                        throws org.apache.camel.component.file.GenericFileOperationFailedException
        Specified by:
        disconnect in interface org.apache.camel.component.file.remote.RemoteFileOperations<ScpFile>
        Throws:
        org.apache.camel.component.file.GenericFileOperationFailedException
      • forceDisconnect

        public void forceDisconnect()
                             throws org.apache.camel.component.file.GenericFileOperationFailedException
        Specified by:
        forceDisconnect in interface org.apache.camel.component.file.remote.RemoteFileOperations<ScpFile>
        Throws:
        org.apache.camel.component.file.GenericFileOperationFailedException
      • sendNoop

        public boolean sendNoop()
                         throws org.apache.camel.component.file.GenericFileOperationFailedException
        Specified by:
        sendNoop in interface org.apache.camel.component.file.remote.RemoteFileOperations<ScpFile>
        Throws:
        org.apache.camel.component.file.GenericFileOperationFailedException
      • sendSiteCommand

        public boolean sendSiteCommand​(String command)
                                throws org.apache.camel.component.file.GenericFileOperationFailedException
        Specified by:
        sendSiteCommand in interface org.apache.camel.component.file.remote.RemoteFileOperations<ScpFile>
        Throws:
        org.apache.camel.component.file.GenericFileOperationFailedException