This function establishes a connection to a remote Gateway daemon statistics protocol handler, using the specified host name, port number, a pointer to a gateway token, and the address of a char pointer for the statistics C API protocol version.
When the call returns, the gateway token represents the connection to the specified Gateway daemon. The token is required to interact with that Gateway daemon in subsequent C API calls.
The char pointer points to a null-terminated character string. The C API owns the storage for the protocol version character array, and the C API program does not free this storage.
The user application must check that the version of the statistics C API protocol provided by the target Gateway daemon is at least the same as major version number in the compile-time string CTG_STAT_PROTOCOL_VER. This compile-time string is defined in ctgstdat.h, described in the C language header files section. The major version number is the first digit in the compile-time string.