UNPKG

@aneoconsultingfr/armonik.api

Version:

gRPC API to interact with ArmoniK built for the web

29 lines (26 loc) 889 B
import { EventSubscriptionRequest, EventSubscriptionResponse } from "./chunk-TKWEXN23.mjs"; // src/generated/events_service.ts import _m0 from "protobufjs/minimal.js"; import { map } from "rxjs/operators"; var protobufPackage = "armonik.api.grpc.v1.events"; var EventsServiceName = "armonik.api.grpc.v1.events.Events"; var EventsClientImpl = class { constructor(rpc, opts) { this.service = (opts == null ? void 0 : opts.service) || EventsServiceName; this.rpc = rpc; this.GetEvents = this.GetEvents.bind(this); } GetEvents(request) { const data = EventSubscriptionRequest.encode(request).finish(); const result = this.rpc.serverStreamingRequest(this.service, "GetEvents", data); return result.pipe(map((data2) => EventSubscriptionResponse.decode(_m0.Reader.create(data2)))); } }; export { protobufPackage, EventsServiceName, EventsClientImpl };