It also disconnect object from database if needed. Exception handling is omitted for simplicity. Exception handling is omitted for simplicity. Exception handling is omitted for simplicity. Initialize client and connect to server with one call.
Exception handling is omitted for simplicity.
First initialize client then connect to server. Exception handling is omitted for simplicity. Disconnect only if we are really connected. Disconnect is made implicitly in destructor. Exception handling is omitted for simplicity.