import * as MsClient from "cn.keytop.midend.microservice.Client"; 

/**
 * 使用示例：
 * import * as demoCarMsClient from 'stc.ms.DemoCar'
 * 
 * const demoCarMsClient = new demoCarMsClient.DemoCar()
 *  demoCarMsClient.fun1('aaa','bbb','ccc')
 * .catch(error => {console.log(error)})
 * .then(value => {console.log(value)})
 *
 *
 * @author 微服务平台自动生成
 * @desc [车辆服务]接口定义
 * @date 2020-03-26 13:49:33
 **/
export class DemoCar {
  private msId: string = 'stc.ms.DemoCar';
  private version: string = '1.0';
  private authType: MsClient.AuthType = MsClient.AuthType.BASE;
  private serviceClient: MsClient.ServiceClient;

  constructor() {
     this.serviceClient = new MsClient.ServiceClientImpl()
   }

  async getStcCar(carId: string): Promise<GetStcCar$Models.StcCar> {
      let uri = '/stcCar' 
      let sid = `${this.msId}.${uri}` 
      let tags = '' 
      let header = {} 
      let paramMap = {} 
      paramMap = { 'carId': carId      } 
      let response = await this.serviceClient.get(sid, this.version, tags, header, paramMap, this.authType) 
      if(!response){
          return response;
      }else{
    return  new GetStcCar$Models.StcCar(response);
  }
  }

}

export namespace GetStcCar$Models { 
   export class StcCar {
       private _ms_response_data$$$; 

       constructor(value){ 
           this._ms_response_data$$$ = value; 

       } 
        get carId(): string {
           return this._ms_response_data$$$.carId;
        }
        set carId(value:string) {
           this._ms_response_data$$$.carId = value 
        }
        get carNum(): string {
           return this._ms_response_data$$$.carNum;
        }
        set carNum(value:string) {
           this._ms_response_data$$$.carNum = value 
        }
        get carColor(): string {
           return this._ms_response_data$$$.carColor;
        }
        set carColor(value:string) {
           this._ms_response_data$$$.carColor = value 
        }

   }

}

