connect

Connects to Kuzzle using the Protocol argument provided in the constructor options. Subsequent call have no effect if the SDK is already connected.

Signature

Copied to clipboard!
void connect();

Exceptions

Throws a kuzzleio::KuzzleException if there is an error. See how to handle error.

Usage

Copied to clipboard!
try {
  kuzzle->connect();

  std::cout << "Successfully connected" << std::endl;
} catch (kuzzleio::KuzzleException& e) {
  std::cerr << e.what() << std::endl;
}