public interface TunnelAgent
Modifier and Type | Interface and Description |
---|---|
static interface |
TunnelAgent.CloseTunnelCallback
Callback interface returned from
#openTunnel() . |
Modifier and Type | Method and Description |
---|---|
boolean |
checkTunnel(java.lang.String name)
This callback method is called before a tunnel is created, to
determine whether to use this tunnel implementation, or revert
to the default (native) tunnel implementation.
|
TunnelAgent.CloseTunnelCallback |
openTunnel(java.nio.channels.ReadableByteChannel request,
java.nio.channels.WritableByteChannel response,
java.lang.String name,
java.lang.String user,
java.lang.String hostname,
int port)
This callback method is called when a tunnel needs to be
created and the request and response streams attached to it.
|
boolean checkTunnel(java.lang.String name)
name
- the name of the tunnel, as in
svn+name://...false
to defer to the default implementation.TunnelAgent.CloseTunnelCallback openTunnel(java.nio.channels.ReadableByteChannel request, java.nio.channels.WritableByteChannel response, java.lang.String name, java.lang.String user, java.lang.String hostname, int port) throws java.lang.Throwable
request
- The request stream of the tunnel. The tunnel
agent implementation will read requests from this channel
and send them to the tunnel process.response
- The request stream of the tunnel. The tunnel
agent implementation will read requests from this channel
and send them to the tunnel process.name
- the name of the tunnel, as in
svn+name://...user
- the tunnel usernamehostname
- the host part of the svn+tunnel:// URLport
- the port part of the svn+tunnel:// URLTunnelAgent.CloseTunnelCallback
, which will
be invoked when the connection is closed, or
null
.any
- exception will abort the connectionjava.lang.Throwable