UNPKG

@itwin/core-common

Version:

iTwin.js components common to frontend and backend

43 lines 1.79 kB
/** @packageDocumentation * @module RpcInterface */ import { RpcConfiguration, RpcConfigurationSupplier } from "./rpc/core/RpcConfiguration"; import { RpcRoutingToken } from "./rpc/core/RpcRoutingToken"; /** * Specifies the required static properties of an RpcInterface class. * These properties are used to identify RPC requests and responses. * @beta */ export interface RpcInterfaceDefinition<T extends RpcInterface = RpcInterface> { prototype: T; interfaceName: string; interfaceVersion: string; } /** * A class that implements the operations of an RPC interface. * @beta */ export type RpcInterfaceImplementation<T extends RpcInterface = RpcInterface> = new () => T; /** An RPC interface is a set of operations exposed by a service that a client can call, using configurable protocols, * in a platform-independent way. TheRpcInterface class is the base class for RPC interface definitions and implementations. * @public */ export declare abstract class RpcInterface { private static findDiff; private static parseVer; /** Determines whether the backend version of an RPC interface is compatible (according to semantic versioning) with the frontend version of the interface. */ static isVersionCompatible(backend: string, frontend: string): boolean; /** The configuration for the RPC interface. * @internal */ readonly configuration: RpcConfiguration; /** @internal */ readonly routing: RpcRoutingToken; /** @beta */ constructor(routing?: RpcRoutingToken); /** Obtains the implementation result for an RPC operation. */ forward<T = any>(parameters: IArguments): Promise<T>; /** @internal */ configurationSupplier: RpcConfigurationSupplier | undefined; } //# sourceMappingURL=RpcInterface.d.ts.map