code: public synchronized void setTransport(Transport v)
     {
        if (transport != null)
        {
           if (transport instanceof NotificationListener)
              listeners.remove((NotificationListener)transport);
  
           removeDistributedStatistics();
        }
  
        transport = v;
  
        if (transport != null)
        {
           if (transport instanceof NotificationListener)
              listeners.add((NotificationListener)transport);
  
           initDistributedStatistics();
        }
     }
docs: {@inheritDoc}