public class UnixAgentFactory extends Object implements SshAgentFactory, ExecutorServiceConfigurer
Constructor and Description |
---|
UnixAgentFactory() |
UnixAgentFactory(ExecutorService service,
boolean shutdown) |
Modifier and Type | Method and Description |
---|---|
SshAgent |
createClient(FactoryManager manager)
Create an SshAgent that can be used on the client side by the authentication
process to send possible keys.
|
SshAgentServer |
createServer(ConnectionService service)
Create the server side that will be used by other SSH clients.
|
NamedFactory<Channel> |
getChannelForwardingFactory()
The channels are requested by the ssh server when forwarding a client request.
|
ExecutorService |
getExecutorService() |
boolean |
isShutdownOnExit() |
void |
setExecutorService(ExecutorService service) |
void |
setShutdownOnExit(boolean shutdown) |
public UnixAgentFactory()
public UnixAgentFactory(ExecutorService service, boolean shutdown)
public ExecutorService getExecutorService()
getExecutorService
in interface ExecutorServiceCarrier
public void setExecutorService(ExecutorService service)
setExecutorService
in interface ExecutorServiceConfigurer
public boolean isShutdownOnExit()
isShutdownOnExit
in interface ExecutorServiceCarrier
true
then the ExecutorService.shutdownNow()
will be called (unless it is an internally allocated service which is always
closed)public void setShutdownOnExit(boolean shutdown)
setShutdownOnExit
in interface ExecutorServiceConfigurer
public NamedFactory<Channel> getChannelForwardingFactory()
SshAgentFactory
getChannelForwardingFactory
in interface SshAgentFactory
public SshAgent createClient(FactoryManager manager) throws IOException
SshAgentFactory
createClient
in interface SshAgentFactory
manager
- The FactoryManager
instanceSshAgent
instanceIOException
- If failed to create the clientpublic SshAgentServer createServer(ConnectionService service) throws IOException
SshAgentFactory
createServer
in interface SshAgentFactory
service
- The ConnectionService
to useSshAgentServer
instanceIOException
- If failed to create the serverCopyright © 2008–2016 The Apache Software Foundation. All rights reserved.