Added new network helper class with inner class to connect to networks
on a new thread