added "connected" method for stateful sessions
authormiker <miker@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Fri, 4 Nov 2005 21:32:45 +0000 (21:32 +0000)
committermiker <miker@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Fri, 4 Nov 2005 21:32:45 +0000 (21:32 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@1961 dcc99617-32d9-48b4-a31d-7c20da2025e4

OpenSRF/src/perlmods/OpenSRF/AppSession.pm

index 679fd16..8e0b484 100644 (file)
@@ -62,6 +62,10 @@ sub transport_connected {
        return $self->{peer_handle}->tcp_connected();
 }
 
+sub connected {
+       my $self = shift;
+       return $self->state == CONNECTED;
+}
 # ----------------------------------------------------------------------------
 # Clears the transport buffers
 # call this if you are not through with the sesssion, but you want