mirror of
https://github.com/tribufu/tribufu-js
synced 2026-06-01 09:42:36 +00:00
Generate code with openapi-generator (#5)
This commit is contained in:
parent
1a8ffe89bc
commit
be21a2496e
67 changed files with 8992 additions and 3492 deletions
201
src/models/IpAddress.ts
Normal file
201
src/models/IpAddress.ts
Normal file
|
|
@ -0,0 +1,201 @@
|
|||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
/**
|
||||
* Tribufu API
|
||||
* REST API to access Tribufu services.
|
||||
*
|
||||
* The version of the OpenAPI document: 1.1.0
|
||||
* Contact: contact@tribufu.com
|
||||
*
|
||||
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
||||
* https://openapi-generator.tech
|
||||
* Do not edit the class manually.
|
||||
*/
|
||||
|
||||
import { mapValues } from '../runtime';
|
||||
/**
|
||||
*
|
||||
* @export
|
||||
* @interface IpAddress
|
||||
*/
|
||||
export interface IpAddress {
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
* @memberof IpAddress
|
||||
*/
|
||||
address?: string | null;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof IpAddress
|
||||
*/
|
||||
version?: number;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
* @memberof IpAddress
|
||||
*/
|
||||
network?: string | null;
|
||||
/**
|
||||
*
|
||||
* @type {boolean}
|
||||
* @memberof IpAddress
|
||||
*/
|
||||
reserved?: boolean;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
* @memberof IpAddress
|
||||
*/
|
||||
asn?: string | null;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
* @memberof IpAddress
|
||||
*/
|
||||
isp?: string | null;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
* @memberof IpAddress
|
||||
*/
|
||||
continent?: string | null;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
* @memberof IpAddress
|
||||
*/
|
||||
country?: string | null;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
* @memberof IpAddress
|
||||
*/
|
||||
region?: string | null;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
* @memberof IpAddress
|
||||
*/
|
||||
city?: string | null;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
* @memberof IpAddress
|
||||
*/
|
||||
postalCode?: string | null;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
* @memberof IpAddress
|
||||
*/
|
||||
callingCode?: string | null;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
* @memberof IpAddress
|
||||
*/
|
||||
tld?: string | null;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
* @memberof IpAddress
|
||||
*/
|
||||
language?: string | null;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
* @memberof IpAddress
|
||||
*/
|
||||
timezone?: string | null;
|
||||
/**
|
||||
*
|
||||
* @type {string}
|
||||
* @memberof IpAddress
|
||||
*/
|
||||
currency?: string | null;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof IpAddress
|
||||
*/
|
||||
latitude?: number | null;
|
||||
/**
|
||||
*
|
||||
* @type {number}
|
||||
* @memberof IpAddress
|
||||
*/
|
||||
longitude?: number | null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if a given object implements the IpAddress interface.
|
||||
*/
|
||||
export function instanceOfIpAddress(value: object): value is IpAddress {
|
||||
return true;
|
||||
}
|
||||
|
||||
export function IpAddressFromJSON(json: any): IpAddress {
|
||||
return IpAddressFromJSONTyped(json, false);
|
||||
}
|
||||
|
||||
export function IpAddressFromJSONTyped(json: any, ignoreDiscriminator: boolean): IpAddress {
|
||||
if (json == null) {
|
||||
return json;
|
||||
}
|
||||
return {
|
||||
|
||||
'address': json['address'] == null ? undefined : json['address'],
|
||||
'version': json['version'] == null ? undefined : json['version'],
|
||||
'network': json['network'] == null ? undefined : json['network'],
|
||||
'reserved': json['reserved'] == null ? undefined : json['reserved'],
|
||||
'asn': json['asn'] == null ? undefined : json['asn'],
|
||||
'isp': json['isp'] == null ? undefined : json['isp'],
|
||||
'continent': json['continent'] == null ? undefined : json['continent'],
|
||||
'country': json['country'] == null ? undefined : json['country'],
|
||||
'region': json['region'] == null ? undefined : json['region'],
|
||||
'city': json['city'] == null ? undefined : json['city'],
|
||||
'postalCode': json['postal_code'] == null ? undefined : json['postal_code'],
|
||||
'callingCode': json['calling_code'] == null ? undefined : json['calling_code'],
|
||||
'tld': json['tld'] == null ? undefined : json['tld'],
|
||||
'language': json['language'] == null ? undefined : json['language'],
|
||||
'timezone': json['timezone'] == null ? undefined : json['timezone'],
|
||||
'currency': json['currency'] == null ? undefined : json['currency'],
|
||||
'latitude': json['latitude'] == null ? undefined : json['latitude'],
|
||||
'longitude': json['longitude'] == null ? undefined : json['longitude'],
|
||||
};
|
||||
}
|
||||
|
||||
export function IpAddressToJSON(json: any): IpAddress {
|
||||
return IpAddressToJSONTyped(json, false);
|
||||
}
|
||||
|
||||
export function IpAddressToJSONTyped(value?: IpAddress | null, ignoreDiscriminator: boolean = false): any {
|
||||
if (value == null) {
|
||||
return value;
|
||||
}
|
||||
|
||||
return {
|
||||
|
||||
'address': value['address'],
|
||||
'version': value['version'],
|
||||
'network': value['network'],
|
||||
'reserved': value['reserved'],
|
||||
'asn': value['asn'],
|
||||
'isp': value['isp'],
|
||||
'continent': value['continent'],
|
||||
'country': value['country'],
|
||||
'region': value['region'],
|
||||
'city': value['city'],
|
||||
'postal_code': value['postalCode'],
|
||||
'calling_code': value['callingCode'],
|
||||
'tld': value['tld'],
|
||||
'language': value['language'],
|
||||
'timezone': value['timezone'],
|
||||
'currency': value['currency'],
|
||||
'latitude': value['latitude'],
|
||||
'longitude': value['longitude'],
|
||||
};
|
||||
}
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue