Package jenkins.plugins.publish_over_ssh
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>
-
Constructor Summary
ConstructorDescriptionBapSshClient
(jenkins.plugins.publish_over.BPBuildInfo buildInfo, com.jcraft.jsch.Session session) BapSshClient
(jenkins.plugins.publish_over.BPBuildInfo buildInfo, com.jcraft.jsch.Session session, boolean disableExec, boolean avoidSameFileUpload) -
Method Summary
Modifier and TypeMethodDescriptionvoid
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.void
beginTransfers
(BapSshTransfer transfer) boolean
changeDirectory
(String directory) void
void
void
disconnectExecQuietly
(com.jcraft.jsch.ChannelExec exec) void
void
endTransfers
(BapSshTransfer transfer) jenkins.plugins.publish_over.BPBuildInfo
com.jcraft.jsch.Session
boolean
boolean
boolean
makeDirectory
(String directory) String[]
parseAllCommands
(BapSshTransfer transfer) String[]
parseCommand
(String command) void
setSftp
(com.jcraft.jsch.ChannelSftp sftp) void
transferFile
(BapSshTransfer bapSshTransfer, FilePath filePath, InputStream inputStream) Methods inherited from class jenkins.plugins.publish_over.BPDefaultClient
changeToInitialDirectory, getAbsoluteRemoteRoot, setAbsoluteRemoteRoot
-
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
- Specified by:
beginTransfers
in interfacejenkins.plugins.publish_over.BPClient<BapSshTransfer>
- Overrides:
beginTransfers
in classjenkins.plugins.publish_over.BPDefaultClient<BapSshTransfer>
-
changeDirectory
-
deleteTree
public void deleteTree() throws com.jcraft.jsch.SftpException- Specified by:
deleteTree
in interfacejenkins.plugins.publish_over.BPClient<BapSshTransfer>
- Overrides:
deleteTree
in classjenkins.plugins.publish_over.BPDefaultClient<BapSshTransfer>
- Throws:
com.jcraft.jsch.SftpException
-
makeDirectory
-
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
- Specified by:
endTransfers
in interfacejenkins.plugins.publish_over.BPClient<BapSshTransfer>
- Overrides:
endTransfers
in classjenkins.plugins.publish_over.BPDefaultClient<BapSshTransfer>
-
parseAllCommands
-
parseCommand
-
disconnectExecQuietly
public void disconnectExecQuietly(com.jcraft.jsch.ChannelExec exec) -
disconnect
public void disconnect() -
disconnectQuietly
public void disconnectQuietly()
-