/** * This file is generated by the SwaggerTSGenerator. * Do not edit. */ /* tslint:disable */ import { BaseModel } from './base-model'; import { SubTypeFactory } from './sub-type-factory'; import { ICountrySubdivisionDataEntry, CountrySubdivisionDataEntry } from './country-subdivision-data-entry.model'; export interface ILocationsImportEntry { alpha2IsoCode?: string; name?: string; region?: string; regionCode?: string; subDivisions?: Array; subRegion?: string; subRegionCode?: string; } export class LocationsImportEntry extends BaseModel implements ILocationsImportEntry { static ALPHA_2_ISO_CODE_FIELD_NAME = 'alpha2IsoCode'; static NAME_FIELD_NAME = 'name'; static REGION_FIELD_NAME = 'region'; static REGION_CODE_FIELD_NAME = 'regionCode'; static SUB_DIVISIONS_FIELD_NAME = 'subDivisions'; static SUB_REGION_FIELD_NAME = 'subRegion'; static SUB_REGION_CODE_FIELD_NAME = 'subRegionCode'; alpha2IsoCode: string; name: string; region: string; regionCode: string; subDivisions: Array; subRegion: string; subRegionCode: string; /** * constructor * @param values Can be used to set a webapi response or formValues to this newly constructed model */ constructor(values?: Partial) { super(); this.subDivisions = new Array(); if (values) { this.setValues(values); } } /** * set the values. * @param values Can be used to set a webapi response to this newly constructed model */ setValues(values: Partial): void { if (values) { const rawValues = values this.alpha2IsoCode = this.getValue(rawValues, LocationsImportEntry.ALPHA_2_ISO_CODE_FIELD_NAME); this.name = this.getValue(rawValues, LocationsImportEntry.NAME_FIELD_NAME); this.region = this.getValue(rawValues, LocationsImportEntry.REGION_FIELD_NAME); this.regionCode = this.getValue(rawValues, LocationsImportEntry.REGION_CODE_FIELD_NAME); this.fillModelArray(this, LocationsImportEntry.SUB_DIVISIONS_FIELD_NAME, rawValues.subDivisions, CountrySubdivisionDataEntry, SubTypeFactory.createSubTypeInstance); this.subRegion = this.getValue(rawValues, LocationsImportEntry.SUB_REGION_FIELD_NAME); this.subRegionCode = this.getValue(rawValues, LocationsImportEntry.SUB_REGION_CODE_FIELD_NAME); } } }