public DatastoreClientImpl(Datastore.IDatastoreClient grpcClient, DatastoreSettings settings) { this.GrpcClient = grpcClient; DatastoreSettings effectiveSettings = settings ?? DatastoreSettings.GetDefault(); _clientHelper = new ClientHelper(effectiveSettings); }
/// <summary> /// Wrap a GRPC Datastore client for more convenient use. /// </summary> /// <param name="grpcClient">A GRPC client to wrap.</param> /// <param name="settings"> /// An optional <see cref="DatastoreSettings"/> to configure this wrapper. /// If null or not specified, then the default settings are used. /// </param> /// <returns>A <see cref="DatastoreClient"/> that wraps the specified GRPC client.</returns> public static DatastoreClient ToClient( this Datastore.IDatastoreClient grpcClient, DatastoreSettings settings = null ) => new DatastoreClientImpl(grpcClient, settings);