/* tslint:disable */ /* eslint-disable */ /** * * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: * * * 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'; import type { DailyReturn } from './DailyReturn'; import { DailyReturnFromJSON, DailyReturnFromJSONTyped, DailyReturnToJSON, } from './DailyReturn'; import type { SharePrice } from './SharePrice'; import { SharePriceFromJSON, SharePriceFromJSONTyped, SharePriceToJSON, } from './SharePrice'; import type { Strategy } from './Strategy'; import { StrategyFromJSON, StrategyFromJSONTyped, StrategyToJSON, } from './Strategy'; /** * * @export * @interface PublicPoolInfo */ export interface PublicPoolInfo { /** * * @type {number} * @memberof PublicPoolInfo */ status: number; /** * * @type {string} * @memberof PublicPoolInfo */ operator_fee: string; /** * * @type {string} * @memberof PublicPoolInfo */ min_operator_share_rate: string; /** * * @type {number} * @memberof PublicPoolInfo */ total_shares: number; /** * * @type {number} * @memberof PublicPoolInfo */ operator_shares: number; /** * * @type {number} * @memberof PublicPoolInfo */ annual_percentage_yield: number; /** * * @type {number} * @memberof PublicPoolInfo */ sharpe_ratio: number; /** * * @type {Array} * @memberof PublicPoolInfo */ daily_returns: Array; /** * * @type {Array} * @memberof PublicPoolInfo */ share_prices: Array; /** * * @type {Array} * @memberof PublicPoolInfo */ strategies: Array; } /** * Check if a given object implements the PublicPoolInfo interface. */ export function instanceOfPublicPoolInfo(value: object): value is PublicPoolInfo { if (!('status' in value) || value['status'] === undefined) return false; if (!('operator_fee' in value) || value['operator_fee'] === undefined) return false; if (!('min_operator_share_rate' in value) || value['min_operator_share_rate'] === undefined) return false; if (!('total_shares' in value) || value['total_shares'] === undefined) return false; if (!('operator_shares' in value) || value['operator_shares'] === undefined) return false; if (!('annual_percentage_yield' in value) || value['annual_percentage_yield'] === undefined) return false; if (!('sharpe_ratio' in value) || value['sharpe_ratio'] === undefined) return false; if (!('daily_returns' in value) || value['daily_returns'] === undefined) return false; if (!('share_prices' in value) || value['share_prices'] === undefined) return false; if (!('strategies' in value) || value['strategies'] === undefined) return false; return true; } export function PublicPoolInfoFromJSON(json: any): PublicPoolInfo { return PublicPoolInfoFromJSONTyped(json, false); } export function PublicPoolInfoFromJSONTyped(json: any, ignoreDiscriminator: boolean): PublicPoolInfo { if (json == null) { return json; } return { 'status': json['status'], 'operator_fee': json['operator_fee'], 'min_operator_share_rate': json['min_operator_share_rate'], 'total_shares': json['total_shares'], 'operator_shares': json['operator_shares'], 'annual_percentage_yield': json['annual_percentage_yield'], 'sharpe_ratio': json['sharpe_ratio'], 'daily_returns': ((json['daily_returns'] as Array).map(DailyReturnFromJSON)), 'share_prices': ((json['share_prices'] as Array).map(SharePriceFromJSON)), 'strategies': ((json['strategies'] as Array).map(StrategyFromJSON)), }; } export function PublicPoolInfoToJSON(value?: PublicPoolInfo | null): any { if (value == null) { return value; } return { 'status': value['status'], 'operator_fee': value['operator_fee'], 'min_operator_share_rate': value['min_operator_share_rate'], 'total_shares': value['total_shares'], 'operator_shares': value['operator_shares'], 'annual_percentage_yield': value['annual_percentage_yield'], 'sharpe_ratio': value['sharpe_ratio'], 'daily_returns': ((value['daily_returns'] as Array).map(DailyReturnToJSON)), 'share_prices': ((value['share_prices'] as Array).map(SharePriceToJSON)), 'strategies': ((value['strategies'] as Array).map(StrategyToJSON)), }; }