Extracting SwarmClient to a separate class

The idea is to have all connection logic separated in its own class. In addition to following single responsibility principle it will allow embedding swarm client in applications, so there is no dependency between command line interface and actual implementation. Thoughts?