"use strict";
var __defProp = Object.defineProperty;
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
var __getOwnPropNames = Object.getOwnPropertyNames;
var __hasOwnProp = Object.prototype.hasOwnProperty;
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
var __export = (target, all) => {
  for (var name in all)
    __defProp(target, name, { get: all[name], enumerable: true });
};
var __copyProps = (to, from, except, desc) => {
  if (from && typeof from === "object" || typeof from === "function") {
    for (let key of __getOwnPropNames(from))
      if (!__hasOwnProp.call(to, key) && key !== except)
        __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
  }
  return to;
};
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
var state_service_client_exports = {};
__export(state_service_client_exports, {
  StateServiceClient: () => StateServiceClient
});
module.exports = __toCommonJS(state_service_client_exports);
var import_state_service = require("./state_service.cjs");
var import_runtime_rpc = require("@protobuf-ts/runtime-rpc");
class StateServiceClient {
  constructor(_transport) {
    this._transport = _transport;
    __publicField(this, "typeName", import_state_service.StateService.typeName);
    __publicField(this, "methods", import_state_service.StateService.methods);
    __publicField(this, "options", import_state_service.StateService.options);
  }
  /**
   * Returns a stream of the snapshot of the active contracts and incomplete (un)assignments at a ledger offset.
   * If there are no active contracts, the stream returns a single response message with the offset at which the snapshot has been taken.
   * Clients SHOULD use the offset in the last GetActiveContractsResponse message to continue streaming transactions with the update service.
   * Clients SHOULD NOT assume that the set of active contracts they receive reflects the state at the ledger end.
   *
   * @generated from protobuf rpc: GetActiveContracts
   */
  getActiveContracts(input, options) {
    const method = this.methods[0], opt = this._transport.mergeOptions(options);
    return (0, import_runtime_rpc.stackIntercept)("serverStreaming", this._transport, method, opt, input);
  }
  /**
   * Get the list of connected synchronizers at the time of the query.
   *
   * @generated from protobuf rpc: GetConnectedSynchronizers
   */
  getConnectedSynchronizers(input, options) {
    const method = this.methods[1], opt = this._transport.mergeOptions(options);
    return (0, import_runtime_rpc.stackIntercept)("unary", this._transport, method, opt, input);
  }
  /**
   * Get the current ledger end.
   * Subscriptions started with the returned offset will serve events after this RPC was called.
   *
   * @generated from protobuf rpc: GetLedgerEnd
   */
  getLedgerEnd(input, options) {
    const method = this.methods[2], opt = this._transport.mergeOptions(options);
    return (0, import_runtime_rpc.stackIntercept)(
      "unary",
      this._transport,
      method,
      opt,
      input
    );
  }
  /**
   * Get the latest successfully pruned ledger offsets
   *
   * @generated from protobuf rpc: GetLatestPrunedOffsets
   */
  getLatestPrunedOffsets(input, options) {
    const method = this.methods[3], opt = this._transport.mergeOptions(options);
    return (0, import_runtime_rpc.stackIntercept)("unary", this._transport, method, opt, input);
  }
}
// Annotate the CommonJS export names for ESM import in node:
0 && (module.exports = {
  StateServiceClient
});
//# sourceMappingURL=state_service.client.cjs.map