UNPKG

@simplyhomes/sos-sdk

Version:

TypeScript SDK for Simply Homes SoS API v4

99 lines (98 loc) 4.62 kB
/* tslint:disable */ /* eslint-disable */ /** * API v4 * Swagger documentation for API v4 * * The version of the OpenAPI document: 4.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ /** * Check if a given object implements the SoSLenderEntityBase interface. */ export function instanceOfSoSLenderEntityBase(value) { if (!('lid' in value) || value['lid'] === undefined) return false; if (!('name' in value) || value['name'] === undefined) return false; if (!('bridgeLoanLoanToPurchasePrice' in value) || value['bridgeLoanLoanToPurchasePrice'] === undefined) return false; if (!('bridgeLoanLoanToRefinanceCost' in value) || value['bridgeLoanLoanToRefinanceCost'] === undefined) return false; if (!('bridgeLoanInterestRate' in value) || value['bridgeLoanInterestRate'] === undefined) return false; if (!('longTermRateAndTermInterestRate' in value) || value['longTermRateAndTermInterestRate'] === undefined) return false; if (!('longTermCashOutInterestRate' in value) || value['longTermCashOutInterestRate'] === undefined) return false; if (!('longTermRateAndTermLoanToValue' in value) || value['longTermRateAndTermLoanToValue'] === undefined) return false; if (!('longTermCashOutLoanToValue' in value) || value['longTermCashOutLoanToValue'] === undefined) return false; if (!('bridgeLoanLoanToCost' in value) || value['bridgeLoanLoanToCost'] === undefined) return false; if (!('bridgeLoanLoanToAsIs' in value) || value['bridgeLoanLoanToAsIs'] === undefined) return false; if (!('bridgeLoanLoanToArv' in value) || value['bridgeLoanLoanToArv'] === undefined) return false; if (!('originationPoints' in value) || value['originationPoints'] === undefined) return false; if (!('loanProcessingFee' in value) || value['loanProcessingFee'] === undefined) return false; return true; } export function SoSLenderEntityBaseFromJSON(json) { return SoSLenderEntityBaseFromJSONTyped(json, false); } export function SoSLenderEntityBaseFromJSONTyped(json, ignoreDiscriminator) { if (json == null) { return json; } return { ...json, // Preserve relation fields from views 'lid': json['lid'], 'name': json['name'], 'bridgeLoanLoanToPurchasePrice': json['bridgeLoanLoanToPurchasePrice'], 'bridgeLoanLoanToRefinanceCost': json['bridgeLoanLoanToRefinanceCost'], 'bridgeLoanInterestRate': json['bridgeLoanInterestRate'], 'longTermRateAndTermInterestRate': json['longTermRateAndTermInterestRate'], 'longTermCashOutInterestRate': json['longTermCashOutInterestRate'], 'longTermRateAndTermLoanToValue': json['longTermRateAndTermLoanToValue'], 'longTermCashOutLoanToValue': json['longTermCashOutLoanToValue'], 'bridgeLoanLoanToCost': json['bridgeLoanLoanToCost'], 'bridgeLoanLoanToAsIs': json['bridgeLoanLoanToAsIs'], 'bridgeLoanLoanToArv': json['bridgeLoanLoanToArv'], 'originationPoints': json['originationPoints'], 'loanProcessingFee': json['loanProcessingFee'], 'organizationId': json['organizationId'] == null ? undefined : json['organizationId'], }; } export function SoSLenderEntityBaseToJSON(json) { return SoSLenderEntityBaseToJSONTyped(json, false); } export function SoSLenderEntityBaseToJSONTyped(value, ignoreDiscriminator = false) { if (value == null) { return value; } return { 'lid': value['lid'], 'name': value['name'], 'bridgeLoanLoanToPurchasePrice': value['bridgeLoanLoanToPurchasePrice'], 'bridgeLoanLoanToRefinanceCost': value['bridgeLoanLoanToRefinanceCost'], 'bridgeLoanInterestRate': value['bridgeLoanInterestRate'], 'longTermRateAndTermInterestRate': value['longTermRateAndTermInterestRate'], 'longTermCashOutInterestRate': value['longTermCashOutInterestRate'], 'longTermRateAndTermLoanToValue': value['longTermRateAndTermLoanToValue'], 'longTermCashOutLoanToValue': value['longTermCashOutLoanToValue'], 'bridgeLoanLoanToCost': value['bridgeLoanLoanToCost'], 'bridgeLoanLoanToAsIs': value['bridgeLoanLoanToAsIs'], 'bridgeLoanLoanToArv': value['bridgeLoanLoanToArv'], 'originationPoints': value['originationPoints'], 'loanProcessingFee': value['loanProcessingFee'], 'organizationId': value['organizationId'], }; }