Package aQute.remote.agent
Class SocketRedirector
java.lang.Object
aQute.remote.agent.SocketRedirector
- All Implemented Interfaces:
Redirector,Closeable,AutoCloseable
A redirector that will open a connection to a socket, assuming there is a
shell running there.
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
SocketRedirector
Constructor- Parameters:
agentServer- the agent we're working forport- the shell port- Throws:
Exception
-
-
Method Details
-
close
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Throws:
IOException
-
getPort
public int getPort()Description copied from interface:RedirectorThe port (or pseudo port) this one is connected to- Specified by:
getPortin interfaceRedirector- Returns:
- the port
-
stdin
Description copied from interface:RedirectorProvide input- Specified by:
stdinin interfaceRedirector- Parameters:
s- the input- Throws:
Exception
-
getOut
Description copied from interface:RedirectorGet the output stream- Specified by:
getOutin interfaceRedirector- Throws:
Exception
-