From 0285fe371ab4a656bb7d7429f15f363435881e05 Mon Sep 17 00:00:00 2001 From: Michael Jumper Date: Fri, 23 Mar 2012 15:31:03 -0700 Subject: [PATCH] Rename attach/detach listeners to connect/close. --- ...Listener.java => TunnelCloseListener.java} | 22 +++++++++--------- ...stener.java => TunnelConnectListener.java} | 23 ++++++++++--------- 2 files changed, 23 insertions(+), 22 deletions(-) rename guacamole-ext/src/main/java/net/sourceforge/guacamole/net/event/listener/{TunnelDetachListener.java => TunnelCloseListener.java} (56%) rename guacamole-ext/src/main/java/net/sourceforge/guacamole/net/event/listener/{TunnelAttachListener.java => TunnelConnectListener.java} (55%) diff --git a/guacamole-ext/src/main/java/net/sourceforge/guacamole/net/event/listener/TunnelDetachListener.java b/guacamole-ext/src/main/java/net/sourceforge/guacamole/net/event/listener/TunnelCloseListener.java similarity index 56% rename from guacamole-ext/src/main/java/net/sourceforge/guacamole/net/event/listener/TunnelDetachListener.java rename to guacamole-ext/src/main/java/net/sourceforge/guacamole/net/event/listener/TunnelCloseListener.java index 88395841a..0eb89703c 100644 --- a/guacamole-ext/src/main/java/net/sourceforge/guacamole/net/event/listener/TunnelDetachListener.java +++ b/guacamole-ext/src/main/java/net/sourceforge/guacamole/net/event/listener/TunnelCloseListener.java @@ -4,28 +4,28 @@ import net.sourceforge.guacamole.GuacamoleException; import net.sourceforge.guacamole.net.event.TunnelCloseEvent; /** - * A listener whose tunnelDetached() hook will fire immediately after an - * existing tunnel is detached from a session. + * A listener whose tunnelClosed() hook will fire immediately after an + * existing tunnel is closed. * * @author Michael Jumper */ -public interface TunnelDetachListener { +public interface TunnelCloseListener { /** - * Event hook which fires immediately after an existing tunnel is detached - * from a session. The return value of this hook dictates whether the - * tunnel is allowed to be detached. + * Event hook which fires immediately after an existing tunnel is closed. + * The return value of this hook dictates whether the tunnel is allowed to + * be closed. * - * @param e The TunnelCloseEvent describing the tunnel being detached and + * @param e The TunnelCloseEvent describing the tunnel being closed and * any associated credentials. - * @return true if the tunnel should be allowed to be detached, or false + * @return true if the tunnel should be allowed to be closed, or false * if the attempt should be denied, causing the attempt to * effectively fail. * @throws GuacamoleException If an error occurs while handling the - * tunnel detach event. Throwing an exception - * will also stop the tunnel from being detached. + * tunnel close event. Throwing an exception + * will also stop the tunnel from being closed. */ - public boolean tunnelDetached(TunnelCloseEvent e) + public boolean tunnelClosed(TunnelCloseEvent e) throws GuacamoleException; } diff --git a/guacamole-ext/src/main/java/net/sourceforge/guacamole/net/event/listener/TunnelAttachListener.java b/guacamole-ext/src/main/java/net/sourceforge/guacamole/net/event/listener/TunnelConnectListener.java similarity index 55% rename from guacamole-ext/src/main/java/net/sourceforge/guacamole/net/event/listener/TunnelAttachListener.java rename to guacamole-ext/src/main/java/net/sourceforge/guacamole/net/event/listener/TunnelConnectListener.java index f15859638..a59f8f9e5 100644 --- a/guacamole-ext/src/main/java/net/sourceforge/guacamole/net/event/listener/TunnelAttachListener.java +++ b/guacamole-ext/src/main/java/net/sourceforge/guacamole/net/event/listener/TunnelConnectListener.java @@ -4,28 +4,29 @@ import net.sourceforge.guacamole.GuacamoleException; import net.sourceforge.guacamole.net.event.TunnelConnectEvent; /** - * A listener whose tunnelAttached() hook will fire immediately after a new - * tunnel is attached to a session. + * A listener whose tunnelConnected() hook will fire immediately after a new + * tunnel is connected. * * @author Michael Jumper */ -public interface TunnelAttachListener { +public interface TunnelConnectListener { /** - * Event hook which fires immediately after a new tunnel is attached to a - * session. The return value of this hook dictates whether the tunnel is - * allowed to be attached. + * Event hook which fires immediately after a new tunnel is connected. + * The return value of this hook dictates whether the tunnel is made visible + * to the session. * - * @param e The TunnelConnectEvent describing the tunnel being attached and + * @param e The TunnelConnectEvent describing the tunnel being connected and * any associated credentials. - * @return true if the tunnel should be allowed to be attached, or false + * @return true if the tunnel should be allowed to be connected, or false * if the attempt should be denied, causing the attempt to * effectively fail. * @throws GuacamoleException If an error occurs while handling the - * tunnel attach event. Throwing an exception - * will also stop the tunnel from being attached. + * tunnel connect event. Throwing an exception + * will also stop the tunnel from being made + * visible to the session. */ - public boolean tunnelAttached(TunnelConnectEvent e) + public boolean tunnelConnected(TunnelConnectEvent e) throws GuacamoleException; }