// package: bet.beteran.member
// file: models/member.proto

import * as jspb from 'google-protobuf';
import * as models_site_pb from '../models/site_pb';
import * as models_member_bank_account_pb from '../models/member_bank_account_pb';
import * as models_member_class_pb from '../models/member_class_pb';
import * as models_member_level_pb from '../models/member_level_pb';
import * as models_member_game_setting_pb from '../models/member_game_setting_pb';
import * as models_member_settlement_setting_pb from '../models/member_settlement_setting_pb';

export class Member extends jspb.Message {
  getId(): string;
  setId(value: string): void;

  getSiteId(): string;
  setSiteId(value: string): void;

  getMemberClassId(): string;
  setMemberClassId(value: string): void;

  getMemberLevelId(): string;
  setMemberLevelId(value: string): void;

  hasParentMemberId(): boolean;
  clearParentMemberId(): void;
  getParentMemberId(): string;
  setParentMemberId(value: string): void;

  getChildMemberCount(): number;
  setChildMemberCount(value: number): void;

  getUsername(): string;
  setUsername(value: string): void;

  getNickname(): string;
  setNickname(value: string): void;

  hasMobilePhoneNumber(): boolean;
  clearMobilePhoneNumber(): void;
  getMobilePhoneNumber(): string;
  setMobilePhoneNumber(value: string): void;

  getState(): MemberStateMap[keyof MemberStateMap];
  setState(value: MemberStateMap[keyof MemberStateMap]): void;

  hasStateChangedAt(): boolean;
  clearStateChangedAt(): void;
  getStateChangedAt(): number;
  setStateChangedAt(value: number): void;

  hasLastSigninedIp(): boolean;
  clearLastSigninedIp(): void;
  getLastSigninedIp(): string;
  setLastSigninedIp(value: string): void;

  hasLastSigninedAt(): boolean;
  clearLastSigninedAt(): void;
  getLastSigninedAt(): number;
  setLastSigninedAt(value: number): void;

  getCreatedAt(): number;
  setCreatedAt(value: number): void;

  getUpdatedAt(): number;
  setUpdatedAt(value: number): void;

  hasDeletedAt(): boolean;
  clearDeletedAt(): void;
  getDeletedAt(): number;
  setDeletedAt(value: number): void;

  serializeBinary(): Uint8Array;
  toObject(includeInstance?: boolean): Member.AsObject;
  static toObject(includeInstance: boolean, msg: Member): Member.AsObject;
  static extensions: { [key: number]: jspb.ExtensionFieldInfo<jspb.Message> };
  static extensionsBinary: {
    [key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>;
  };
  static serializeBinaryToWriter(
    message: Member,
    writer: jspb.BinaryWriter
  ): void;
  static deserializeBinary(bytes: Uint8Array): Member;
  static deserializeBinaryFromReader(
    message: Member,
    reader: jspb.BinaryReader
  ): Member;
}

export namespace Member {
  export type AsObject = {
    id: string;
    siteId: string;
    memberClassId: string;
    memberLevelId: string;
    parentMemberId: string;
    childMemberCount: number;
    username: string;
    nickname: string;
    mobilePhoneNumber: string;
    state: MemberStateMap[keyof MemberStateMap];
    stateChangedAt: number;
    lastSigninedIp: string;
    lastSigninedAt: number;
    createdAt: number;
    updatedAt: number;
    deletedAt: number;
  };
}

export class MemberModel extends jspb.Message {
  getId(): string;
  setId(value: string): void;

  hasSite(): boolean;
  clearSite(): void;
  getSite(): models_site_pb.Site | undefined;
  setSite(value?: models_site_pb.Site): void;

  hasMemberClass(): boolean;
  clearMemberClass(): void;
  getMemberClass(): models_member_class_pb.MemberClass | undefined;
  setMemberClass(value?: models_member_class_pb.MemberClass): void;

  hasMemberLevel(): boolean;
  clearMemberLevel(): void;
  getMemberLevel(): models_member_level_pb.MemberLevel | undefined;
  setMemberLevel(value?: models_member_level_pb.MemberLevel): void;

  hasBankAccount(): boolean;
  clearBankAccount(): void;
  getBankAccount():
    | models_member_bank_account_pb.MemberBankAccountModel
    | undefined;
  setBankAccount(
    value?: models_member_bank_account_pb.MemberBankAccountModel
  ): void;

  hasParentMember(): boolean;
  clearParentMember(): void;
  getParentMember(): Member | undefined;
  setParentMember(value?: Member): void;

  getChildMemberCount(): number;
  setChildMemberCount(value: number): void;

  getUsername(): string;
  setUsername(value: string): void;

  getNickname(): string;
  setNickname(value: string): void;

  hasMobilePhoneNumber(): boolean;
  clearMobilePhoneNumber(): void;
  getMobilePhoneNumber(): string;
  setMobilePhoneNumber(value: string): void;

  getState(): MemberStateMap[keyof MemberStateMap];
  setState(value: MemberStateMap[keyof MemberStateMap]): void;

  hasStateChangedAt(): boolean;
  clearStateChangedAt(): void;
  getStateChangedAt(): number;
  setStateChangedAt(value: number): void;

  hasMemberGameSetting(): boolean;
  clearMemberGameSetting(): void;
  getMemberGameSetting():
    | models_member_game_setting_pb.MemberGameSetting
    | undefined;
  setMemberGameSetting(
    value?: models_member_game_setting_pb.MemberGameSetting
  ): void;

  hasMemberSettlementSetting(): boolean;
  clearMemberSettlementSetting(): void;
  getMemberSettlementSetting():
    | models_member_settlement_setting_pb.MemberSettlementSetting
    | undefined;
  setMemberSettlementSetting(
    value?: models_member_settlement_setting_pb.MemberSettlementSetting
  ): void;

  hasLastSigninedIp(): boolean;
  clearLastSigninedIp(): void;
  getLastSigninedIp(): string;
  setLastSigninedIp(value: string): void;

  hasLastSigninedAt(): boolean;
  clearLastSigninedAt(): void;
  getLastSigninedAt(): number;
  setLastSigninedAt(value: number): void;

  getCreatedAt(): number;
  setCreatedAt(value: number): void;

  getUpdatedAt(): number;
  setUpdatedAt(value: number): void;

  hasDeletedAt(): boolean;
  clearDeletedAt(): void;
  getDeletedAt(): number;
  setDeletedAt(value: number): void;

  serializeBinary(): Uint8Array;
  toObject(includeInstance?: boolean): MemberModel.AsObject;
  static toObject(
    includeInstance: boolean,
    msg: MemberModel
  ): MemberModel.AsObject;
  static extensions: { [key: number]: jspb.ExtensionFieldInfo<jspb.Message> };
  static extensionsBinary: {
    [key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>;
  };
  static serializeBinaryToWriter(
    message: MemberModel,
    writer: jspb.BinaryWriter
  ): void;
  static deserializeBinary(bytes: Uint8Array): MemberModel;
  static deserializeBinaryFromReader(
    message: MemberModel,
    reader: jspb.BinaryReader
  ): MemberModel;
}

export namespace MemberModel {
  export type AsObject = {
    id: string;
    site?: models_site_pb.Site.AsObject;
    memberClass?: models_member_class_pb.MemberClass.AsObject;
    memberLevel?: models_member_level_pb.MemberLevel.AsObject;
    bankAccount?: models_member_bank_account_pb.MemberBankAccountModel.AsObject;
    parentMember?: Member.AsObject;
    childMemberCount: number;
    username: string;
    nickname: string;
    mobilePhoneNumber: string;
    state: MemberStateMap[keyof MemberStateMap];
    stateChangedAt: number;
    memberGameSetting?: models_member_game_setting_pb.MemberGameSetting.AsObject;
    memberSettlementSetting?: models_member_settlement_setting_pb.MemberSettlementSetting.AsObject;
    lastSigninedIp: string;
    lastSigninedAt: number;
    createdAt: number;
    updatedAt: number;
    deletedAt: number;
  };
}

export interface MemberStateMap {
  NONE: 0;
  NORMAL: 1;
  PENDING: 2;
  WITHDRAWAL: 3;
  DORMANCY: 4;
  BLACKLIST: 5;
  SUSPENDED: 6;
}

export const MemberState: MemberStateMap;
