Class BapSshClient

java.lang.Object
jenkins.plugins.publish_over.BPDefaultClient<BapSshTransfer>
jenkins.plugins.publish_over_ssh.BapSshClient
All Implemented Interfaces:
jenkins.plugins.publish_over.BPClient<BapSshTransfer>

public class BapSshClient extends jenkins.plugins.publish_over.BPDefaultClient<BapSshTransfer>
  • Constructor Details

    • BapSshClient

      public BapSshClient(jenkins.plugins.publish_over.BPBuildInfo buildInfo, com.jcraft.jsch.Session session)
    • BapSshClient

      public BapSshClient(jenkins.plugins.publish_over.BPBuildInfo buildInfo, com.jcraft.jsch.Session session, boolean disableExec, boolean avoidSameFileUpload)
  • Method Details

    • addSession

      public void addSession(com.jcraft.jsch.Session session)
      Add a new session to the already known session chain (forwarding) The new session will become the current session.
      Parameters:
      session - new session to add
    • isDisableExec

      public boolean isDisableExec()
    • isAvoidSameFileUpload

      public boolean isAvoidSameFileUpload()
    • getBuildInfo

      public jenkins.plugins.publish_over.BPBuildInfo getBuildInfo()
    • setSftp

      public void setSftp(com.jcraft.jsch.ChannelSftp sftp)
    • getSession

      public com.jcraft.jsch.Session getSession()
    • beginTransfers

      public void beginTransfers(BapSshTransfer transfer)
      Specified by:
      beginTransfers in interface jenkins.plugins.publish_over.BPClient<BapSshTransfer>
      Overrides:
      beginTransfers in class jenkins.plugins.publish_over.BPDefaultClient<BapSshTransfer>
    • changeDirectory

      public boolean changeDirectory(String directory)
    • deleteTree

      public void deleteTree() throws com.jcraft.jsch.SftpException
      Specified by:
      deleteTree in interface jenkins.plugins.publish_over.BPClient<BapSshTransfer>
      Overrides:
      deleteTree in class jenkins.plugins.publish_over.BPDefaultClient<BapSshTransfer>
      Throws:
      com.jcraft.jsch.SftpException
    • makeDirectory

      public boolean makeDirectory(String directory)
    • transferFile

      public void transferFile(BapSshTransfer bapSshTransfer, FilePath filePath, InputStream inputStream) throws com.jcraft.jsch.SftpException, IOException, InterruptedException
      Throws:
      com.jcraft.jsch.SftpException
      IOException
      InterruptedException
    • endTransfers

      public void endTransfers(BapSshTransfer transfer)
      Specified by:
      endTransfers in interface jenkins.plugins.publish_over.BPClient<BapSshTransfer>
      Overrides:
      endTransfers in class jenkins.plugins.publish_over.BPDefaultClient<BapSshTransfer>
    • parseAllCommands

      public String[] parseAllCommands(BapSshTransfer transfer)
    • parseCommand

      public String[] parseCommand(String command)
    • disconnectExecQuietly

      public void disconnectExecQuietly(com.jcraft.jsch.ChannelExec exec)
    • disconnect

      public void disconnect()
    • disconnectQuietly

      public void disconnectQuietly()