public Session createSession(boolean transacted,int acknowledgeMode) throws JMSException {
  if (closed) {
    throw new IllegalStateException("Forbidden call on a closed connection.");
  }
  GSSessionImpl session=new GSSessionImpl(this,transacted,acknowledgeMode);
  if (!isStopped()) {
    session.start();
  }
  return session;
}

public Session createSession ( boolean transacted , int acknowledgeMode ) throws JMSException { if ( closed ) { throw new IllegalStateException ( "Forbidden call on a closed connection." ) ; } GSSessionImpl session = new GSSessionImpl ( this , transacted , acknowledgeMode ) ; if ( ! isStopped ( ) ) { session . start ( ) ; } return session ; }
use the extended methods , from gstopicconnectionimpl for topic and from gsqueueconnectionimpl for queue .
