-
Notifications
You must be signed in to change notification settings - Fork 1.4k
/
Copy pathrpc.d.ts
48 lines (42 loc) · 2.35 KB
/
rpc.d.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
import * as $protobuf from "../..";
export class MyService extends $protobuf.rpc.Service {
constructor(rpcImpl: $protobuf.RPCImpl, requestDelimited?: boolean, responseDelimited?: boolean);
public static create(rpcImpl: $protobuf.RPCImpl, requestDelimited?: boolean, responseDelimited?: boolean): MyService;
public myMethod(request: IMyRequest, callback: MyService.MyMethodCallback): void;
public myMethod(request: IMyRequest): Promise<MyResponse>;
}
export namespace MyService {
type MyMethodCallback = (error: (Error|null), response?: MyResponse) => void;
}
export interface IMyRequest {
path?: (string|null);
}
export class MyRequest implements IMyRequest {
constructor(properties?: IMyRequest);
public path: string;
public static create(properties?: IMyRequest): MyRequest;
public static encode(message: IMyRequest, writer?: $protobuf.Writer): $protobuf.Writer;
public static encodeDelimited(message: IMyRequest, writer?: $protobuf.Writer): $protobuf.Writer;
public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): MyRequest;
public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): MyRequest;
public static verify(message: { [k: string]: any }): (string|null);
public static fromObject(object: { [k: string]: any }): MyRequest;
public static toObject(message: MyRequest, options?: $protobuf.IConversionOptions): { [k: string]: any };
public toJSON(): { [k: string]: any };
}
export interface IMyResponse {
status?: (number|null);
}
export class MyResponse implements IMyResponse {
constructor(properties?: IMyResponse);
public status: number;
public static create(properties?: IMyResponse): MyResponse;
public static encode(message: IMyResponse, writer?: $protobuf.Writer): $protobuf.Writer;
public static encodeDelimited(message: IMyResponse, writer?: $protobuf.Writer): $protobuf.Writer;
public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): MyResponse;
public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): MyResponse;
public static verify(message: { [k: string]: any }): (string|null);
public static fromObject(object: { [k: string]: any }): MyResponse;
public static toObject(message: MyResponse, options?: $protobuf.IConversionOptions): { [k: string]: any };
public toJSON(): { [k: string]: any };
}