- Preparing search index...
- The search index is not available
rpc_ts
ModuleRpcProtocolServer
Functions
registerRpcRoutes
- registerRpcRoutes<serviceDefinition>(serviceDefinition: serviceDefinition, serviceHandler: ModuleRpcServer.ServiceHandlerFor<serviceDefinition>, options?: RpcServerOptions): Router
- registerRpcRoutes<serviceDefinition, RequestContext>(serviceDefinition: serviceDefinition, serviceHandler: ModuleRpcServer.ServiceHandlerFor<serviceDefinition, RequestContext>, options: RpcServerOptions & object): Router
-
Type parameters
Parameters
-
serviceDefinition: serviceDefinition
-
serviceHandler: ModuleRpcServer.ServiceHandlerFor<serviceDefinition>
-
Returns Router
-
Type parameters
Parameters
-
serviceDefinition: serviceDefinition
-
serviceHandler: ModuleRpcServer.ServiceHandlerFor<serviceDefinition, RequestContext>
-
Returns Router
This module provides a simplified interface for instantiating an RPC server. Under the hood, it is a thin wrapper around ModuleRpcProtocolGrpcWebServer.registerGrpcWebRoutes, and it provides a gRPC-Web transportation protocol with JSON encoding/decoding. Other protocols could be offered here in the future, and registerRpcRoutes would be used to easily choose between them.
ModuleRpcProtocolClient
Copyright (c) Aiden.ai
This source code is licensed under the MIT license found in the LICENSE file in the root directory of this source tree.