models.ts 329 B

1234567891011121314151617
  1. export namespace config {
  2. export class Config {
  3. servers: string[];
  4. static createFrom(source: any = {}) {
  5. return new Config(source);
  6. }
  7. constructor(source: any = {}) {
  8. if ('string' === typeof source) source = JSON.parse(source);
  9. this.servers = source["servers"];
  10. }
  11. }
  12. }