wrapper for conditionally passing picks onto the client application
[vamsas.git] / src / uk / ac / vamsas / client / simpleclient / SimpleClient.java
index e66cb51..739cf58 100644 (file)
@@ -76,12 +76,12 @@ public class SimpleClient implements IClient {
     _session = sess;
     this.user = user;
     this.client = client;
-    try {
+    //try {
       session = new SessionUrn(_session);
-    } catch (MalformedURLException e) {
+    /*} catch (MalformedURLException e) {
       log.error("Couldn't form a valid SessionUrn object!",e);
       throw new InvalidSessionUrnException(_session.toString());
-    }
+    }*/
   }
   /**
    * construct new session by importing objects from an existing vamsas document
@@ -217,6 +217,7 @@ public class SimpleClient implements IClient {
     // if (handlers.containsKey(Events.CLIENT_FINALIZATION))
     // deregister listeners.
     // mark this instance as finalized
+    this._session.removeClient(this);
   }
   
   /*
@@ -416,6 +417,14 @@ public class SimpleClient implements IClient {
     
   }
 
+  /**
+   * retrieves the current VamsasSession to which belong the client
+   * @return the _session
+   */
+  protected VamsasSession get_session() {
+    return this._session;
+  }
+
   /* (non-Javadoc)
    * @see uk.ac.vamsas.client.IClient#getPickManager()
    */