接入proto
This commit is contained in:
Vendored
+536
@@ -0,0 +1,536 @@
|
||||
declare namespace proto {
|
||||
// DO NOT EDIT! This is a generated file. Edit the JSDoc in src/*.js instead and run 'npm run build:types'.
|
||||
|
||||
/** Properties of a LoginReq. */
|
||||
export interface ILoginReq {
|
||||
|
||||
/** LoginReq username */
|
||||
username?: (string|null);
|
||||
|
||||
/** LoginReq password */
|
||||
password?: (string|null);
|
||||
}
|
||||
|
||||
/** Represents a LoginReq. */
|
||||
export class LoginReq implements ILoginReq {
|
||||
|
||||
/**
|
||||
* Constructs a new LoginReq.
|
||||
* @param [properties] Properties to set
|
||||
*/
|
||||
constructor(properties?: ILoginReq);
|
||||
|
||||
/** LoginReq username. */
|
||||
public username: string;
|
||||
|
||||
/** LoginReq password. */
|
||||
public password: string;
|
||||
|
||||
/**
|
||||
* Creates a new LoginReq instance using the specified properties.
|
||||
* @param [properties] Properties to set
|
||||
* @returns LoginReq instance
|
||||
*/
|
||||
public static create(properties?: ILoginReq): LoginReq;
|
||||
|
||||
/**
|
||||
* Encodes the specified LoginReq message. Does not implicitly {@link LoginReq.verify|verify} messages.
|
||||
* @param message LoginReq message or plain object to encode
|
||||
* @param [writer] Writer to encode to
|
||||
* @returns Writer
|
||||
*/
|
||||
public static encode(message: ILoginReq, writer?: $protobuf.Writer): $protobuf.Writer;
|
||||
|
||||
/**
|
||||
* Encodes the specified LoginReq message, length delimited. Does not implicitly {@link LoginReq.verify|verify} messages.
|
||||
* @param message LoginReq message or plain object to encode
|
||||
* @param [writer] Writer to encode to
|
||||
* @returns Writer
|
||||
*/
|
||||
public static encodeDelimited(message: ILoginReq, writer?: $protobuf.Writer): $protobuf.Writer;
|
||||
|
||||
/**
|
||||
* Decodes a LoginReq message from the specified reader or buffer.
|
||||
* @param reader Reader or buffer to decode from
|
||||
* @param [length] Message length if known beforehand
|
||||
* @returns LoginReq
|
||||
* @throws {Error} If the payload is not a reader or valid buffer
|
||||
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
||||
*/
|
||||
public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): LoginReq;
|
||||
|
||||
/**
|
||||
* Decodes a LoginReq message from the specified reader or buffer, length delimited.
|
||||
* @param reader Reader or buffer to decode from
|
||||
* @returns LoginReq
|
||||
* @throws {Error} If the payload is not a reader or valid buffer
|
||||
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
||||
*/
|
||||
public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): LoginReq;
|
||||
|
||||
/**
|
||||
* Verifies a LoginReq message.
|
||||
* @param message Plain object to verify
|
||||
* @returns `null` if valid, otherwise the reason why it is not
|
||||
*/
|
||||
public static verify(message: { [k: string]: any }): (string|null);
|
||||
|
||||
/**
|
||||
* Creates a LoginReq message from a plain object. Also converts values to their respective internal types.
|
||||
* @param object Plain object
|
||||
* @returns LoginReq
|
||||
*/
|
||||
public static fromObject(object: { [k: string]: any }): LoginReq;
|
||||
|
||||
/**
|
||||
* Creates a plain object from a LoginReq message. Also converts values to other types if specified.
|
||||
* @param message LoginReq
|
||||
* @param [options] Conversion options
|
||||
* @returns Plain object
|
||||
*/
|
||||
public static toObject(message: LoginReq, options?: $protobuf.IConversionOptions): { [k: string]: any };
|
||||
|
||||
/**
|
||||
* Converts this LoginReq to JSON.
|
||||
* @returns JSON object
|
||||
*/
|
||||
public toJSON(): { [k: string]: any };
|
||||
|
||||
/**
|
||||
* Gets the default type url for LoginReq
|
||||
* @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
|
||||
* @returns The default type url
|
||||
*/
|
||||
public static getTypeUrl(typeUrlPrefix?: string): string;
|
||||
}
|
||||
|
||||
/** Properties of a LoginRes. */
|
||||
export interface ILoginRes {
|
||||
|
||||
/** LoginRes success */
|
||||
success?: (boolean|null);
|
||||
|
||||
/** LoginRes token */
|
||||
token?: (string|null);
|
||||
|
||||
/** LoginRes message */
|
||||
message?: (string|null);
|
||||
}
|
||||
|
||||
/** Represents a LoginRes. */
|
||||
export class LoginRes implements ILoginRes {
|
||||
|
||||
/**
|
||||
* Constructs a new LoginRes.
|
||||
* @param [properties] Properties to set
|
||||
*/
|
||||
constructor(properties?: ILoginRes);
|
||||
|
||||
/** LoginRes success. */
|
||||
public success: boolean;
|
||||
|
||||
/** LoginRes token. */
|
||||
public token: string;
|
||||
|
||||
/** LoginRes message. */
|
||||
public message: string;
|
||||
|
||||
/**
|
||||
* Creates a new LoginRes instance using the specified properties.
|
||||
* @param [properties] Properties to set
|
||||
* @returns LoginRes instance
|
||||
*/
|
||||
public static create(properties?: ILoginRes): LoginRes;
|
||||
|
||||
/**
|
||||
* Encodes the specified LoginRes message. Does not implicitly {@link LoginRes.verify|verify} messages.
|
||||
* @param message LoginRes message or plain object to encode
|
||||
* @param [writer] Writer to encode to
|
||||
* @returns Writer
|
||||
*/
|
||||
public static encode(message: ILoginRes, writer?: $protobuf.Writer): $protobuf.Writer;
|
||||
|
||||
/**
|
||||
* Encodes the specified LoginRes message, length delimited. Does not implicitly {@link LoginRes.verify|verify} messages.
|
||||
* @param message LoginRes message or plain object to encode
|
||||
* @param [writer] Writer to encode to
|
||||
* @returns Writer
|
||||
*/
|
||||
public static encodeDelimited(message: ILoginRes, writer?: $protobuf.Writer): $protobuf.Writer;
|
||||
|
||||
/**
|
||||
* Decodes a LoginRes message from the specified reader or buffer.
|
||||
* @param reader Reader or buffer to decode from
|
||||
* @param [length] Message length if known beforehand
|
||||
* @returns LoginRes
|
||||
* @throws {Error} If the payload is not a reader or valid buffer
|
||||
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
||||
*/
|
||||
public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): LoginRes;
|
||||
|
||||
/**
|
||||
* Decodes a LoginRes message from the specified reader or buffer, length delimited.
|
||||
* @param reader Reader or buffer to decode from
|
||||
* @returns LoginRes
|
||||
* @throws {Error} If the payload is not a reader or valid buffer
|
||||
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
||||
*/
|
||||
public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): LoginRes;
|
||||
|
||||
/**
|
||||
* Verifies a LoginRes message.
|
||||
* @param message Plain object to verify
|
||||
* @returns `null` if valid, otherwise the reason why it is not
|
||||
*/
|
||||
public static verify(message: { [k: string]: any }): (string|null);
|
||||
|
||||
/**
|
||||
* Creates a LoginRes message from a plain object. Also converts values to their respective internal types.
|
||||
* @param object Plain object
|
||||
* @returns LoginRes
|
||||
*/
|
||||
public static fromObject(object: { [k: string]: any }): LoginRes;
|
||||
|
||||
/**
|
||||
* Creates a plain object from a LoginRes message. Also converts values to other types if specified.
|
||||
* @param message LoginRes
|
||||
* @param [options] Conversion options
|
||||
* @returns Plain object
|
||||
*/
|
||||
public static toObject(message: LoginRes, options?: $protobuf.IConversionOptions): { [k: string]: any };
|
||||
|
||||
/**
|
||||
* Converts this LoginRes to JSON.
|
||||
* @returns JSON object
|
||||
*/
|
||||
public toJSON(): { [k: string]: any };
|
||||
|
||||
/**
|
||||
* Gets the default type url for LoginRes
|
||||
* @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
|
||||
* @returns The default type url
|
||||
*/
|
||||
public static getTypeUrl(typeUrlPrefix?: string): string;
|
||||
}
|
||||
|
||||
/** Namespace user. */
|
||||
export namespace user {
|
||||
|
||||
/** Properties of a UserInfo. */
|
||||
interface IUserInfo {
|
||||
|
||||
/** UserInfo id */
|
||||
id?: (number|null);
|
||||
|
||||
/** UserInfo nickname */
|
||||
nickname?: (string|null);
|
||||
|
||||
/** UserInfo email */
|
||||
email?: (string|null);
|
||||
}
|
||||
|
||||
/** Represents a UserInfo. */
|
||||
class UserInfo implements IUserInfo {
|
||||
|
||||
/**
|
||||
* Constructs a new UserInfo.
|
||||
* @param [properties] Properties to set
|
||||
*/
|
||||
constructor(properties?: user.IUserInfo);
|
||||
|
||||
/** UserInfo id. */
|
||||
public id: number;
|
||||
|
||||
/** UserInfo nickname. */
|
||||
public nickname: string;
|
||||
|
||||
/** UserInfo email. */
|
||||
public email: string;
|
||||
|
||||
/**
|
||||
* Creates a new UserInfo instance using the specified properties.
|
||||
* @param [properties] Properties to set
|
||||
* @returns UserInfo instance
|
||||
*/
|
||||
public static create(properties?: user.IUserInfo): user.UserInfo;
|
||||
|
||||
/**
|
||||
* Encodes the specified UserInfo message. Does not implicitly {@link user.UserInfo.verify|verify} messages.
|
||||
* @param message UserInfo message or plain object to encode
|
||||
* @param [writer] Writer to encode to
|
||||
* @returns Writer
|
||||
*/
|
||||
public static encode(message: user.IUserInfo, writer?: $protobuf.Writer): $protobuf.Writer;
|
||||
|
||||
/**
|
||||
* Encodes the specified UserInfo message, length delimited. Does not implicitly {@link user.UserInfo.verify|verify} messages.
|
||||
* @param message UserInfo message or plain object to encode
|
||||
* @param [writer] Writer to encode to
|
||||
* @returns Writer
|
||||
*/
|
||||
public static encodeDelimited(message: user.IUserInfo, writer?: $protobuf.Writer): $protobuf.Writer;
|
||||
|
||||
/**
|
||||
* Decodes a UserInfo message from the specified reader or buffer.
|
||||
* @param reader Reader or buffer to decode from
|
||||
* @param [length] Message length if known beforehand
|
||||
* @returns UserInfo
|
||||
* @throws {Error} If the payload is not a reader or valid buffer
|
||||
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
||||
*/
|
||||
public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): user.UserInfo;
|
||||
|
||||
/**
|
||||
* Decodes a UserInfo message from the specified reader or buffer, length delimited.
|
||||
* @param reader Reader or buffer to decode from
|
||||
* @returns UserInfo
|
||||
* @throws {Error} If the payload is not a reader or valid buffer
|
||||
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
||||
*/
|
||||
public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): user.UserInfo;
|
||||
|
||||
/**
|
||||
* Verifies a UserInfo message.
|
||||
* @param message Plain object to verify
|
||||
* @returns `null` if valid, otherwise the reason why it is not
|
||||
*/
|
||||
public static verify(message: { [k: string]: any }): (string|null);
|
||||
|
||||
/**
|
||||
* Creates a UserInfo message from a plain object. Also converts values to their respective internal types.
|
||||
* @param object Plain object
|
||||
* @returns UserInfo
|
||||
*/
|
||||
public static fromObject(object: { [k: string]: any }): user.UserInfo;
|
||||
|
||||
/**
|
||||
* Creates a plain object from a UserInfo message. Also converts values to other types if specified.
|
||||
* @param message UserInfo
|
||||
* @param [options] Conversion options
|
||||
* @returns Plain object
|
||||
*/
|
||||
public static toObject(message: user.UserInfo, options?: $protobuf.IConversionOptions): { [k: string]: any };
|
||||
|
||||
/**
|
||||
* Converts this UserInfo to JSON.
|
||||
* @returns JSON object
|
||||
*/
|
||||
public toJSON(): { [k: string]: any };
|
||||
|
||||
/**
|
||||
* Gets the default type url for UserInfo
|
||||
* @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
|
||||
* @returns The default type url
|
||||
*/
|
||||
public static getTypeUrl(typeUrlPrefix?: string): string;
|
||||
}
|
||||
|
||||
/** Properties of a GetUserReq. */
|
||||
interface IGetUserReq {
|
||||
|
||||
/** GetUserReq id */
|
||||
id?: (number|null);
|
||||
}
|
||||
|
||||
/** Represents a GetUserReq. */
|
||||
class GetUserReq implements IGetUserReq {
|
||||
|
||||
/**
|
||||
* Constructs a new GetUserReq.
|
||||
* @param [properties] Properties to set
|
||||
*/
|
||||
constructor(properties?: user.IGetUserReq);
|
||||
|
||||
/** GetUserReq id. */
|
||||
public id: number;
|
||||
|
||||
/**
|
||||
* Creates a new GetUserReq instance using the specified properties.
|
||||
* @param [properties] Properties to set
|
||||
* @returns GetUserReq instance
|
||||
*/
|
||||
public static create(properties?: user.IGetUserReq): user.GetUserReq;
|
||||
|
||||
/**
|
||||
* Encodes the specified GetUserReq message. Does not implicitly {@link user.GetUserReq.verify|verify} messages.
|
||||
* @param message GetUserReq message or plain object to encode
|
||||
* @param [writer] Writer to encode to
|
||||
* @returns Writer
|
||||
*/
|
||||
public static encode(message: user.IGetUserReq, writer?: $protobuf.Writer): $protobuf.Writer;
|
||||
|
||||
/**
|
||||
* Encodes the specified GetUserReq message, length delimited. Does not implicitly {@link user.GetUserReq.verify|verify} messages.
|
||||
* @param message GetUserReq message or plain object to encode
|
||||
* @param [writer] Writer to encode to
|
||||
* @returns Writer
|
||||
*/
|
||||
public static encodeDelimited(message: user.IGetUserReq, writer?: $protobuf.Writer): $protobuf.Writer;
|
||||
|
||||
/**
|
||||
* Decodes a GetUserReq message from the specified reader or buffer.
|
||||
* @param reader Reader or buffer to decode from
|
||||
* @param [length] Message length if known beforehand
|
||||
* @returns GetUserReq
|
||||
* @throws {Error} If the payload is not a reader or valid buffer
|
||||
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
||||
*/
|
||||
public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): user.GetUserReq;
|
||||
|
||||
/**
|
||||
* Decodes a GetUserReq message from the specified reader or buffer, length delimited.
|
||||
* @param reader Reader or buffer to decode from
|
||||
* @returns GetUserReq
|
||||
* @throws {Error} If the payload is not a reader or valid buffer
|
||||
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
||||
*/
|
||||
public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): user.GetUserReq;
|
||||
|
||||
/**
|
||||
* Verifies a GetUserReq message.
|
||||
* @param message Plain object to verify
|
||||
* @returns `null` if valid, otherwise the reason why it is not
|
||||
*/
|
||||
public static verify(message: { [k: string]: any }): (string|null);
|
||||
|
||||
/**
|
||||
* Creates a GetUserReq message from a plain object. Also converts values to their respective internal types.
|
||||
* @param object Plain object
|
||||
* @returns GetUserReq
|
||||
*/
|
||||
public static fromObject(object: { [k: string]: any }): user.GetUserReq;
|
||||
|
||||
/**
|
||||
* Creates a plain object from a GetUserReq message. Also converts values to other types if specified.
|
||||
* @param message GetUserReq
|
||||
* @param [options] Conversion options
|
||||
* @returns Plain object
|
||||
*/
|
||||
public static toObject(message: user.GetUserReq, options?: $protobuf.IConversionOptions): { [k: string]: any };
|
||||
|
||||
/**
|
||||
* Converts this GetUserReq to JSON.
|
||||
* @returns JSON object
|
||||
*/
|
||||
public toJSON(): { [k: string]: any };
|
||||
|
||||
/**
|
||||
* Gets the default type url for GetUserReq
|
||||
* @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
|
||||
* @returns The default type url
|
||||
*/
|
||||
public static getTypeUrl(typeUrlPrefix?: string): string;
|
||||
}
|
||||
|
||||
/** Properties of a GetUserRes. */
|
||||
interface IGetUserRes {
|
||||
|
||||
/** GetUserRes success */
|
||||
success?: (boolean|null);
|
||||
|
||||
/** GetUserRes data */
|
||||
data?: (user.IUserInfo|null);
|
||||
|
||||
/** GetUserRes message */
|
||||
message?: (string|null);
|
||||
}
|
||||
|
||||
/** Represents a GetUserRes. */
|
||||
class GetUserRes implements IGetUserRes {
|
||||
|
||||
/**
|
||||
* Constructs a new GetUserRes.
|
||||
* @param [properties] Properties to set
|
||||
*/
|
||||
constructor(properties?: user.IGetUserRes);
|
||||
|
||||
/** GetUserRes success. */
|
||||
public success: boolean;
|
||||
|
||||
/** GetUserRes data. */
|
||||
public data?: (user.IUserInfo|null);
|
||||
|
||||
/** GetUserRes message. */
|
||||
public message: string;
|
||||
|
||||
/**
|
||||
* Creates a new GetUserRes instance using the specified properties.
|
||||
* @param [properties] Properties to set
|
||||
* @returns GetUserRes instance
|
||||
*/
|
||||
public static create(properties?: user.IGetUserRes): user.GetUserRes;
|
||||
|
||||
/**
|
||||
* Encodes the specified GetUserRes message. Does not implicitly {@link user.GetUserRes.verify|verify} messages.
|
||||
* @param message GetUserRes message or plain object to encode
|
||||
* @param [writer] Writer to encode to
|
||||
* @returns Writer
|
||||
*/
|
||||
public static encode(message: user.IGetUserRes, writer?: $protobuf.Writer): $protobuf.Writer;
|
||||
|
||||
/**
|
||||
* Encodes the specified GetUserRes message, length delimited. Does not implicitly {@link user.GetUserRes.verify|verify} messages.
|
||||
* @param message GetUserRes message or plain object to encode
|
||||
* @param [writer] Writer to encode to
|
||||
* @returns Writer
|
||||
*/
|
||||
public static encodeDelimited(message: user.IGetUserRes, writer?: $protobuf.Writer): $protobuf.Writer;
|
||||
|
||||
/**
|
||||
* Decodes a GetUserRes message from the specified reader or buffer.
|
||||
* @param reader Reader or buffer to decode from
|
||||
* @param [length] Message length if known beforehand
|
||||
* @returns GetUserRes
|
||||
* @throws {Error} If the payload is not a reader or valid buffer
|
||||
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
||||
*/
|
||||
public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): user.GetUserRes;
|
||||
|
||||
/**
|
||||
* Decodes a GetUserRes message from the specified reader or buffer, length delimited.
|
||||
* @param reader Reader or buffer to decode from
|
||||
* @returns GetUserRes
|
||||
* @throws {Error} If the payload is not a reader or valid buffer
|
||||
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
||||
*/
|
||||
public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): user.GetUserRes;
|
||||
|
||||
/**
|
||||
* Verifies a GetUserRes message.
|
||||
* @param message Plain object to verify
|
||||
* @returns `null` if valid, otherwise the reason why it is not
|
||||
*/
|
||||
public static verify(message: { [k: string]: any }): (string|null);
|
||||
|
||||
/**
|
||||
* Creates a GetUserRes message from a plain object. Also converts values to their respective internal types.
|
||||
* @param object Plain object
|
||||
* @returns GetUserRes
|
||||
*/
|
||||
public static fromObject(object: { [k: string]: any }): user.GetUserRes;
|
||||
|
||||
/**
|
||||
* Creates a plain object from a GetUserRes message. Also converts values to other types if specified.
|
||||
* @param message GetUserRes
|
||||
* @param [options] Conversion options
|
||||
* @returns Plain object
|
||||
*/
|
||||
public static toObject(message: user.GetUserRes, options?: $protobuf.IConversionOptions): { [k: string]: any };
|
||||
|
||||
/**
|
||||
* Converts this GetUserRes to JSON.
|
||||
* @returns JSON object
|
||||
*/
|
||||
public toJSON(): { [k: string]: any };
|
||||
|
||||
/**
|
||||
* Gets the default type url for GetUserRes
|
||||
* @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
|
||||
* @returns The default type url
|
||||
*/
|
||||
public static getTypeUrl(typeUrlPrefix?: string): string;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
export default proto;
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user