@gitchrisqueen/tdameritrade-api-js-client
Version:
TD Ameritrade API integration for node.js
90 lines (75 loc) • 2.55 kB
JavaScript
/**
* TD Ameritrade API - OAuth2
* This is replication of the TD Ameritrade API.
*
* OpenAPI spec version: 0.1.4
*
*
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
*/
import ApiClient from '../ApiClient';
/**
* The ExecutionExecutionLegs model module.
* @module model/ExecutionExecutionLegs
* @version 0.1.4
*/
export default class ExecutionExecutionLegs {
/**
* Constructs a new <code>ExecutionExecutionLegs</code>.
* @alias module:model/ExecutionExecutionLegs
* @class
*/
constructor() {
}
/**
* Constructs a <code>ExecutionExecutionLegs</code> from a plain JavaScript object, optionally creating a new instance.
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
* @param {Object} data The plain JavaScript object bearing properties of interest.
* @param {module:model/ExecutionExecutionLegs} obj Optional instance to populate.
* @return {module:model/ExecutionExecutionLegs} The populated <code>ExecutionExecutionLegs</code> instance.
*/
static constructFromObject(data, obj) {
if (data) {
obj = obj || new ExecutionExecutionLegs();
if (data.hasOwnProperty('legId')) {
obj['legId'] = ApiClient.convertToType(data['legId'], 'Number');
}
if (data.hasOwnProperty('quantity')) {
obj['quantity'] = ApiClient.convertToType(data['quantity'], 'Number');
}
if (data.hasOwnProperty('mismarkedQuantity')) {
obj['mismarkedQuantity'] = ApiClient.convertToType(data['mismarkedQuantity'], 'Number');
}
if (data.hasOwnProperty('price')) {
obj['price'] = ApiClient.convertToType(data['price'], 'Number');
}
if (data.hasOwnProperty('time')) {
obj['time'] = ApiClient.convertToType(data['time'], 'Date');
}
}
return obj;
}
/**
* @member {Number} legId
*/
'legId' = undefined;
/**
* @member {Number} quantity
*/
'quantity' = undefined;
/**
* @member {Number} mismarkedQuantity
*/
'mismarkedQuantity' = undefined;
/**
* @member {Number} price
*/
'price' = undefined;
/**
* @member {Date} time
*/
'time' = undefined;
}