title: How do I disconnect my XMPPPY client object
body: <p>Connecting to an XMPP server with XMPPPY is simple.</p>
  
  <pre><code>from xmpp.client import Client as XMPPClient
  
  self.xmppClient = XMPPClient("jabber.foo.com")
  if not self.xmppClient.connect(server="localhost"):
      raise IOError('Cannot connect to server.')
  if not self.xmppClient.auth("node", "password", "resource"):
      raise IOError('Can not auth with server.')
      self.xmppClient.RegisterHandler("message", self.messageHandler)
  self.xmppClient.sendInitPresence()
  </code></pre>
  
  <p>However, there are times when my client has to force a disconnect, yet still keep going doing other things.  I'd like to make sure that the client disconnects properly - that the socket is not 'hanging around' and the server resources are not being wasted.</p>
  
  <p>Is the intended pattern to simply set the client to None and let GC clean up the object?</p>
  
  <pre><code>self.xmppClient = None
  </code></pre>
  
  <p>I see "disconnected handlers" in the client, but I do not see how to invoke them.  And the documentation that comes with XMPPPY is horrible.</p>
  
  <p>Anyone have any clue of the "right way" to disconnect?</p>