Reorganizing of methods

Added new option ('autoReconnect'), which when set to false will prevent the connection from being automatically reconnected after a disconnect.