TCP Target Connection Status in Client

Is there a way to monitor (or be notified of changes to) the connection status with a TCP target? I see this information in the server terminal window, for example:

(TCP) Connection established (192.168.10.14:1337)
(TCP) Connection closed (192.168.10.14:1337)
(TCP) Attempting reconnection in 5s (192.168.10.14:1337)
(TCP) Connection established (192.168.10.14:1337)

I would like to use this information for two purposes:

  1. A connection status indicator in the client gui.
  2. When the server obtains connection to the target, I would like to synchronize the target's current settings with the client gui.

It's not possible currently, but it could be at some point (most likely with a custom module), I'm bookmarking this for later.