JobService constructor

JobService({
  1. required Client client,
  2. Uri? endPoint,
  3. String? gcclVersion,
})

Creates a JobService using client for transport.

The provided http.Client must be configured to provide whatever authentication is required by JobService. You can do that using package:googleapis_auth.

If endPoint is provided then its scheme, host, and port are used for all API requests. For example, Uri.http('127.0.0.1:8080') could be used to force the Firestore service to communicate with the local emulator.

If gcclVersion is set then gccl/<version> will be included in the x-google-api-client header. This argument is only meant for use by hand-written official Google Cloud API clients.

Implementation

JobService({required http.Client client, Uri? endPoint, String? gcclVersion})
  : _client = ServiceClient(
      client: client,
      gapicVersion: packageVersion,
      gcclVersion: gcclVersion,
    ),
    _endPoint = endPoint == null
        ? Uri.https(_defaultHost, '')
        : Uri(
            scheme: endPoint.scheme,
            host: endPoint.host,
            port: endPoint.port,
          );