/// <summary>
 /// Initializes a new instance of the <see cref="TargetTaxLot" /> class.
 /// </summary>
 /// <param name="units">The number of units of the instrument in this tax-lot. (required).</param>
 /// <param name="cost">cost.</param>
 /// <param name="portfolioCost">The total cost of the tax-lot in the transaction portfolio&#39;s base currency..</param>
 /// <param name="price">The purchase price of each unit of the instrument held in this tax-lot. This forms part of the unique key required for multiple tax-lots..</param>
 /// <param name="purchaseDate">The purchase date of this tax-lot. This forms part of the unique key required for multiple tax-lots..</param>
 /// <param name="settlementDate">The settlement date of the tax-lot&#39;s opening transaction..</param>
 public TargetTaxLot(decimal units = default(decimal), CurrencyAndAmount cost = default(CurrencyAndAmount), decimal?portfolioCost = default(decimal?), decimal?price = default(decimal?), DateTimeOffset?purchaseDate = default(DateTimeOffset?), DateTimeOffset?settlementDate = default(DateTimeOffset?))
 {
     this.Units          = units;
     this.Cost           = cost;
     this.PortfolioCost  = portfolioCost;
     this.Price          = price;
     this.PurchaseDate   = purchaseDate;
     this.SettlementDate = settlementDate;
 }
示例#2
0
        /// <summary>
        /// Initializes a new instance of the <see cref="RealisedGainLoss" /> class.
        /// </summary>
        /// <param name="costTradeCcy">costTradeCcy (required).</param>
        /// <param name="costPortfolioCcy">costPortfolioCcy (required).</param>
        /// <param name="realisedTradeCcy">realisedTradeCcy (required).</param>
        /// <param name="realisedTotal">realisedTotal (required).</param>
        /// <param name="realisedMarket">realisedMarket.</param>
        /// <param name="realisedCurrency">realisedCurrency.</param>
        public RealisedGainLoss(CurrencyAndAmount costTradeCcy = default(CurrencyAndAmount), CurrencyAndAmount costPortfolioCcy = default(CurrencyAndAmount), CurrencyAndAmount realisedTradeCcy = default(CurrencyAndAmount), CurrencyAndAmount realisedTotal = default(CurrencyAndAmount), CurrencyAndAmount realisedMarket = default(CurrencyAndAmount), CurrencyAndAmount realisedCurrency = default(CurrencyAndAmount))
        {
            // to ensure "costTradeCcy" is required (not null)
            if (costTradeCcy == null)
            {
                throw new InvalidDataException("costTradeCcy is a required property for RealisedGainLoss and cannot be null");
            }
            else
            {
                this.CostTradeCcy = costTradeCcy;
            }

            // to ensure "costPortfolioCcy" is required (not null)
            if (costPortfolioCcy == null)
            {
                throw new InvalidDataException("costPortfolioCcy is a required property for RealisedGainLoss and cannot be null");
            }
            else
            {
                this.CostPortfolioCcy = costPortfolioCcy;
            }

            // to ensure "realisedTradeCcy" is required (not null)
            if (realisedTradeCcy == null)
            {
                throw new InvalidDataException("realisedTradeCcy is a required property for RealisedGainLoss and cannot be null");
            }
            else
            {
                this.RealisedTradeCcy = realisedTradeCcy;
            }

            // to ensure "realisedTotal" is required (not null)
            if (realisedTotal == null)
            {
                throw new InvalidDataException("realisedTotal is a required property for RealisedGainLoss and cannot be null");
            }
            else
            {
                this.RealisedTotal = realisedTotal;
            }

            this.RealisedMarket   = realisedMarket;
            this.RealisedCurrency = realisedCurrency;
        }
        /// <summary>
        /// Initializes a new instance of the <see cref="TargetTaxLot" /> class.
        /// </summary>
        /// <param name="units">The number of units of the instrument in this tax-lot. (required).</param>
        /// <param name="cost">cost.</param>
        /// <param name="portfolioCost">The total cost of the tax-lot in the transaction portfolio&#39;s base currency..</param>
        /// <param name="price">The purchase price of each unit of the instrument held in this tax-lot. This forms part of the unique key required for multiple tax-lots..</param>
        /// <param name="purchaseDate">The purchase date of this tax-lot. This forms part of the unique key required for multiple tax-lots..</param>
        /// <param name="settlementDate">The settlement date of the tax-lot&#39;s opening transaction..</param>
        public TargetTaxLot(double?units = default(double?), CurrencyAndAmount cost = default(CurrencyAndAmount), double?portfolioCost = default(double?), double?price = default(double?), DateTimeOffset?purchaseDate = default(DateTimeOffset?), DateTimeOffset?settlementDate = default(DateTimeOffset?))
        {
            // to ensure "units" is required (not null)
            if (units == null)
            {
                throw new InvalidDataException("units is a required property for TargetTaxLot and cannot be null");
            }
            else
            {
                this.Units = units;
            }

            this.Cost           = cost;
            this.PortfolioCost  = portfolioCost;
            this.Price          = price;
            this.PurchaseDate   = purchaseDate;
            this.SettlementDate = settlementDate;
        }
示例#4
0
        /// <summary>
        /// Initializes a new instance of the <see cref="RealisedGainLoss" /> class.
        /// </summary>
        /// <param name="instrumentUid">The unqiue Lusid Instrument Id (LUID) of the instrument that this gain or loss is associated with. (required).</param>
        /// <param name="units">The number of units of the associated instrument against which the gain or loss has been realised. (required).</param>
        /// <param name="purchasePrice">The purchase price of each unit associated with this gain or loss..</param>
        /// <param name="costTradeCcy">costTradeCcy (required).</param>
        /// <param name="costPortfolioCcy">costPortfolioCcy (required).</param>
        /// <param name="realisedTradeCcy">realisedTradeCcy (required).</param>
        /// <param name="realisedTotal">realisedTotal (required).</param>
        /// <param name="realisedMarket">realisedMarket.</param>
        /// <param name="realisedCurrency">realisedCurrency.</param>
        public RealisedGainLoss(string instrumentUid = default(string), decimal?units = default(decimal?), decimal?purchasePrice = default(decimal?), CurrencyAndAmount costTradeCcy = default(CurrencyAndAmount), CurrencyAndAmount costPortfolioCcy = default(CurrencyAndAmount), CurrencyAndAmount realisedTradeCcy = default(CurrencyAndAmount), CurrencyAndAmount realisedTotal = default(CurrencyAndAmount), CurrencyAndAmount realisedMarket = default(CurrencyAndAmount), CurrencyAndAmount realisedCurrency = default(CurrencyAndAmount))
        {
            // to ensure "instrumentUid" is required (not null)
            if (instrumentUid == null)
            {
                throw new InvalidDataException("instrumentUid is a required property for RealisedGainLoss and cannot be null");
            }
            else
            {
                this.InstrumentUid = instrumentUid;
            }

            // to ensure "units" is required (not null)
            if (units == null)
            {
                throw new InvalidDataException("units is a required property for RealisedGainLoss and cannot be null");
            }
            else
            {
                this.Units = units;
            }

            this.PurchasePrice = purchasePrice;
            // to ensure "costTradeCcy" is required (not null)
            if (costTradeCcy == null)
            {
                throw new InvalidDataException("costTradeCcy is a required property for RealisedGainLoss and cannot be null");
            }
            else
            {
                this.CostTradeCcy = costTradeCcy;
            }

            // to ensure "costPortfolioCcy" is required (not null)
            if (costPortfolioCcy == null)
            {
                throw new InvalidDataException("costPortfolioCcy is a required property for RealisedGainLoss and cannot be null");
            }
            else
            {
                this.CostPortfolioCcy = costPortfolioCcy;
            }

            // to ensure "realisedTradeCcy" is required (not null)
            if (realisedTradeCcy == null)
            {
                throw new InvalidDataException("realisedTradeCcy is a required property for RealisedGainLoss and cannot be null");
            }
            else
            {
                this.RealisedTradeCcy = realisedTradeCcy;
            }

            // to ensure "realisedTotal" is required (not null)
            if (realisedTotal == null)
            {
                throw new InvalidDataException("realisedTotal is a required property for RealisedGainLoss and cannot be null");
            }
            else
            {
                this.RealisedTotal = realisedTotal;
            }

            this.PurchasePrice    = purchasePrice;
            this.RealisedMarket   = realisedMarket;
            this.RealisedCurrency = realisedCurrency;
        }
示例#5
0
        /// <summary>
        /// Initializes a new instance of the <see cref="TransactionRequest" /> class.
        /// </summary>
        /// <param name="transactionId">The unique identifier for the transaction. (required).</param>
        /// <param name="type">The type of the transaction e.g. &#39;Buy&#39;, &#39;Sell&#39;. The transaction type should have been pre-configured via the System Configuration API endpoint. If it hasn&#39;t been pre-configured the transaction will still be updated or inserted however you will be unable to generate the resultant holdings for the portfolio that contains this transaction as LUSID does not know how to process it. (required).</param>
        /// <param name="instrumentIdentifiers">A set of instrument identifiers to use to resolve the transaction to a unique instrument. (required).</param>
        /// <param name="transactionDate">The date of the transaction. (required).</param>
        /// <param name="settlementDate">The settlement date of the transaction. (required).</param>
        /// <param name="units">The number of units transacted in the associated instrument. (required).</param>
        /// <param name="transactionPrice">transactionPrice.</param>
        /// <param name="totalConsideration">totalConsideration (required).</param>
        /// <param name="exchangeRate">The exchange rate between the transaction and settlement currency. For example if the transaction currency is in USD and the settlement currency is in GBP this this the USD/GBP rate..</param>
        /// <param name="transactionCurrency">The transaction currency..</param>
        /// <param name="properties">Set of unique transaction properties and associated values to store with the transaction. Each property must be from the &#39;Transaction&#39; domain..</param>
        /// <param name="counterpartyId">The identifier for the counterparty of the transaction..</param>
        /// <param name="source">The source of the transaction. This is used to look up the appropriate transaction group set in the transaction type configuration..</param>
        public TransactionRequest(string transactionId = default(string), string type = default(string), Dictionary <string, string> instrumentIdentifiers = default(Dictionary <string, string>), DateTimeOrCutLabel transactionDate = default(DateTimeOrCutLabel), DateTimeOrCutLabel settlementDate = default(DateTimeOrCutLabel), decimal?units = default(decimal?), TransactionPrice transactionPrice = default(TransactionPrice), CurrencyAndAmount totalConsideration = default(CurrencyAndAmount), decimal?exchangeRate = default(decimal?), string transactionCurrency = default(string), Dictionary <string, PerpetualProperty> properties = default(Dictionary <string, PerpetualProperty>), string counterpartyId = default(string), string source = default(string))
        {
            // to ensure "transactionId" is required (not null)
            if (transactionId == null)
            {
                throw new InvalidDataException("transactionId is a required property for TransactionRequest and cannot be null");
            }
            else
            {
                this.TransactionId = transactionId;
            }

            // to ensure "type" is required (not null)
            if (type == null)
            {
                throw new InvalidDataException("type is a required property for TransactionRequest and cannot be null");
            }
            else
            {
                this.Type = type;
            }

            // to ensure "instrumentIdentifiers" is required (not null)
            if (instrumentIdentifiers == null)
            {
                throw new InvalidDataException("instrumentIdentifiers is a required property for TransactionRequest and cannot be null");
            }
            else
            {
                this.InstrumentIdentifiers = instrumentIdentifiers;
            }

            // to ensure "transactionDate" is required (not null)
            if (transactionDate == null)
            {
                throw new InvalidDataException("transactionDate is a required property for TransactionRequest and cannot be null");
            }
            else
            {
                this.TransactionDate = transactionDate;
            }

            // to ensure "settlementDate" is required (not null)
            if (settlementDate == null)
            {
                throw new InvalidDataException("settlementDate is a required property for TransactionRequest and cannot be null");
            }
            else
            {
                this.SettlementDate = settlementDate;
            }

            // to ensure "units" is required (not null)
            if (units == null)
            {
                throw new InvalidDataException("units is a required property for TransactionRequest and cannot be null");
            }
            else
            {
                this.Units = units;
            }

            // to ensure "totalConsideration" is required (not null)
            if (totalConsideration == null)
            {
                throw new InvalidDataException("totalConsideration is a required property for TransactionRequest and cannot be null");
            }
            else
            {
                this.TotalConsideration = totalConsideration;
            }

            this.ExchangeRate        = exchangeRate;
            this.TransactionCurrency = transactionCurrency;
            this.Properties          = properties;
            this.CounterpartyId      = counterpartyId;
            this.Source              = source;
            this.TransactionPrice    = transactionPrice;
            this.ExchangeRate        = exchangeRate;
            this.TransactionCurrency = transactionCurrency;
            this.Properties          = properties;
            this.CounterpartyId      = counterpartyId;
            this.Source              = source;
        }
示例#6
0
        /// <summary>
        /// Initializes a new instance of the <see cref="PortfolioHolding" /> class.
        /// </summary>
        /// <param name="instrumentUid">The unqiue Lusid Instrument Id (LUID) of the instrument that the holding is in. (required).</param>
        /// <param name="subHoldingKeys">The sub-holding properties which identify the holding. Each property will be from the &#39;Transaction&#39; domain. These are configured when a transaction portfolio is created..</param>
        /// <param name="properties">The properties which have been requested to be decorated onto the holding. These will be from the &#39;Instrument&#39; or &#39;Holding&#39; domain..</param>
        /// <param name="holdingType">The type of the holding e.g. Position, Balance, CashCommitment, Receivable, ForwardFX etc. (required).</param>
        /// <param name="units">The total number of units of the holding. (required).</param>
        /// <param name="settledUnits">The total number of settled units of the holding. (required).</param>
        /// <param name="cost">cost (required).</param>
        /// <param name="costPortfolioCcy">costPortfolioCcy (required).</param>
        /// <param name="transaction">transaction.</param>
        public PortfolioHolding(string instrumentUid = default(string), Dictionary <string, PerpetualProperty> subHoldingKeys = default(Dictionary <string, PerpetualProperty>), Dictionary <string, Property> properties = default(Dictionary <string, Property>), string holdingType = default(string), double?units = default(double?), double?settledUnits = default(double?), CurrencyAndAmount cost = default(CurrencyAndAmount), CurrencyAndAmount costPortfolioCcy = default(CurrencyAndAmount), Transaction transaction = default(Transaction))
        {
            // to ensure "instrumentUid" is required (not null)
            if (instrumentUid == null)
            {
                throw new InvalidDataException("instrumentUid is a required property for PortfolioHolding and cannot be null");
            }
            else
            {
                this.InstrumentUid = instrumentUid;
            }

            // to ensure "holdingType" is required (not null)
            if (holdingType == null)
            {
                throw new InvalidDataException("holdingType is a required property for PortfolioHolding and cannot be null");
            }
            else
            {
                this.HoldingType = holdingType;
            }

            // to ensure "units" is required (not null)
            if (units == null)
            {
                throw new InvalidDataException("units is a required property for PortfolioHolding and cannot be null");
            }
            else
            {
                this.Units = units;
            }

            // to ensure "settledUnits" is required (not null)
            if (settledUnits == null)
            {
                throw new InvalidDataException("settledUnits is a required property for PortfolioHolding and cannot be null");
            }
            else
            {
                this.SettledUnits = settledUnits;
            }

            // to ensure "cost" is required (not null)
            if (cost == null)
            {
                throw new InvalidDataException("cost is a required property for PortfolioHolding and cannot be null");
            }
            else
            {
                this.Cost = cost;
            }

            // to ensure "costPortfolioCcy" is required (not null)
            if (costPortfolioCcy == null)
            {
                throw new InvalidDataException("costPortfolioCcy is a required property for PortfolioHolding and cannot be null");
            }
            else
            {
                this.CostPortfolioCcy = costPortfolioCcy;
            }

            this.SubHoldingKeys = subHoldingKeys;
            this.Properties     = properties;
            this.Transaction    = transaction;
        }
        /// <summary>
        /// Initializes a new instance of the <see cref="ReconciliationBreak" /> class.
        /// </summary>
        /// <param name="instrumentUid">Unique instrument identifier (required).</param>
        /// <param name="subHoldingKeys">Any other properties that comprise the Sub-Holding Key (required).</param>
        /// <param name="leftUnits">Units from the left hand side (required).</param>
        /// <param name="rightUnits">Units from the right hand side (required).</param>
        /// <param name="differenceUnits">Difference in units (required).</param>
        /// <param name="leftCost">leftCost (required).</param>
        /// <param name="rightCost">rightCost (required).</param>
        /// <param name="differenceCost">differenceCost (required).</param>
        /// <param name="instrumentProperties">Additional features relating to the instrument (required).</param>
        public ReconciliationBreak(string instrumentUid = default(string), Dictionary <string, PerpetualProperty> subHoldingKeys = default(Dictionary <string, PerpetualProperty>), decimal?leftUnits = default(decimal?), decimal?rightUnits = default(decimal?), decimal?differenceUnits = default(decimal?), CurrencyAndAmount leftCost = default(CurrencyAndAmount), CurrencyAndAmount rightCost = default(CurrencyAndAmount), CurrencyAndAmount differenceCost = default(CurrencyAndAmount), List <Property> instrumentProperties = default(List <Property>))
        {
            // to ensure "instrumentUid" is required (not null)
            if (instrumentUid == null)
            {
                throw new InvalidDataException("instrumentUid is a required property for ReconciliationBreak and cannot be null");
            }
            else
            {
                this.InstrumentUid = instrumentUid;
            }

            // to ensure "subHoldingKeys" is required (not null)
            if (subHoldingKeys == null)
            {
                throw new InvalidDataException("subHoldingKeys is a required property for ReconciliationBreak and cannot be null");
            }
            else
            {
                this.SubHoldingKeys = subHoldingKeys;
            }

            // to ensure "leftUnits" is required (not null)
            if (leftUnits == null)
            {
                throw new InvalidDataException("leftUnits is a required property for ReconciliationBreak and cannot be null");
            }
            else
            {
                this.LeftUnits = leftUnits;
            }

            // to ensure "rightUnits" is required (not null)
            if (rightUnits == null)
            {
                throw new InvalidDataException("rightUnits is a required property for ReconciliationBreak and cannot be null");
            }
            else
            {
                this.RightUnits = rightUnits;
            }

            // to ensure "differenceUnits" is required (not null)
            if (differenceUnits == null)
            {
                throw new InvalidDataException("differenceUnits is a required property for ReconciliationBreak and cannot be null");
            }
            else
            {
                this.DifferenceUnits = differenceUnits;
            }

            // to ensure "leftCost" is required (not null)
            if (leftCost == null)
            {
                throw new InvalidDataException("leftCost is a required property for ReconciliationBreak and cannot be null");
            }
            else
            {
                this.LeftCost = leftCost;
            }

            // to ensure "rightCost" is required (not null)
            if (rightCost == null)
            {
                throw new InvalidDataException("rightCost is a required property for ReconciliationBreak and cannot be null");
            }
            else
            {
                this.RightCost = rightCost;
            }

            // to ensure "differenceCost" is required (not null)
            if (differenceCost == null)
            {
                throw new InvalidDataException("differenceCost is a required property for ReconciliationBreak and cannot be null");
            }
            else
            {
                this.DifferenceCost = differenceCost;
            }

            // to ensure "instrumentProperties" is required (not null)
            if (instrumentProperties == null)
            {
                throw new InvalidDataException("instrumentProperties is a required property for ReconciliationBreak and cannot be null");
            }
            else
            {
                this.InstrumentProperties = instrumentProperties;
            }
        }
 /// <summary>
 /// Initializes a new instance of the <see cref="AllocationRequest" /> class.
 /// </summary>
 /// <param name="properties">Client-defined properties associated with this allocation..</param>
 /// <param name="instrumentIdentifiers">The instrument allocated. (required).</param>
 /// <param name="quantity">The quantity of given instrument allocated. (required).</param>
 /// <param name="portfolioId">portfolioId (required).</param>
 /// <param name="allocatedOrderId">allocatedOrderId (required).</param>
 /// <param name="id">id (required).</param>
 /// <param name="placementIds">A placement - also known as an order placed in the market - associated with this allocation..</param>
 /// <param name="state">The state of this allocation..</param>
 /// <param name="side">The side of this allocation (examples: Buy, Sell, ...)..</param>
 /// <param name="type">The type of order associated with this allocation (examples: Limit, Market, ...)..</param>
 /// <param name="settlementDate">The settlement date for this allocation..</param>
 /// <param name="date">The date of this allocation..</param>
 /// <param name="price">price.</param>
 /// <param name="settlementCurrency">The settlement currency of this allocation..</param>
 /// <param name="settlementCurrencyFxRate">The settlement currency to allocation currency FX rate..</param>
 /// <param name="counterparty">The counterparty for this allocation..</param>
 public AllocationRequest(Dictionary <string, PerpetualProperty> properties = default(Dictionary <string, PerpetualProperty>), Dictionary <string, string> instrumentIdentifiers = default(Dictionary <string, string>), int quantity = default(int), ResourceId portfolioId = default(ResourceId), ResourceId allocatedOrderId = default(ResourceId), ResourceId id = default(ResourceId), List <ResourceId> placementIds = default(List <ResourceId>), string state = default(string), string side = default(string), string type = default(string), DateTimeOffset?settlementDate = default(DateTimeOffset?), DateTimeOffset date = default(DateTimeOffset), CurrencyAndAmount price = default(CurrencyAndAmount), string settlementCurrency = default(string), decimal?settlementCurrencyFxRate = default(decimal?), string counterparty = default(string))
 {
     // to ensure "instrumentIdentifiers" is required (not null)
     this.InstrumentIdentifiers = instrumentIdentifiers ?? throw new ArgumentNullException("instrumentIdentifiers is a required property for AllocationRequest and cannot be null");
     this.Quantity = quantity;
     // to ensure "portfolioId" is required (not null)
     this.PortfolioId = portfolioId ?? throw new ArgumentNullException("portfolioId is a required property for AllocationRequest and cannot be null");
     // to ensure "allocatedOrderId" is required (not null)
     this.AllocatedOrderId = allocatedOrderId ?? throw new ArgumentNullException("allocatedOrderId is a required property for AllocationRequest and cannot be null");
     // to ensure "id" is required (not null)
     this.Id                       = id ?? throw new ArgumentNullException("id is a required property for AllocationRequest and cannot be null");
     this.Properties               = properties;
     this.PlacementIds             = placementIds;
     this.State                    = state;
     this.Side                     = side;
     this.Type                     = type;
     this.SettlementDate           = settlementDate;
     this.Date                     = date;
     this.Price                    = price;
     this.SettlementCurrency       = settlementCurrency;
     this.SettlementCurrencyFxRate = settlementCurrencyFxRate;
     this.Counterparty             = counterparty;
 }
示例#9
0
 /// <summary>
 /// Initializes a new instance of the <see cref="OutputTransaction" /> class.
 /// </summary>
 /// <param name="transactionId">The unique identifier for the transaction. (required).</param>
 /// <param name="type">The type of the transaction e.g. &#39;Buy&#39;, &#39;Sell&#39;. The transaction type should have been pre-configured via the System Configuration API endpoint. (required).</param>
 /// <param name="description">The description of the transaction. This only exists on transactions generated by LUSID e.g. a holdings adjustment transaction..</param>
 /// <param name="instrumentIdentifiers">A set of instrument identifiers that can resolve the transaction to a unique instrument..</param>
 /// <param name="instrumentScope">The scope in which the instrument lies..</param>
 /// <param name="instrumentUid">The unqiue Lusid Instrument Id (LUID) of the instrument that the transaction is in. (required).</param>
 /// <param name="transactionDate">The date of the transaction. (required).</param>
 /// <param name="settlementDate">The settlement date of the transaction. (required).</param>
 /// <param name="units">The number of units transacted in the associated instrument. (required).</param>
 /// <param name="transactionAmount">The total value of the transaction in the transaction currency..</param>
 /// <param name="transactionPrice">transactionPrice.</param>
 /// <param name="totalConsideration">totalConsideration.</param>
 /// <param name="exchangeRate">The exchange rate between the transaction and settlement currency (settlement currency being represented by the TotalConsideration.Currency). For example if the transaction currency is in USD and the settlement currency is in GBP this this the USD/GBP rate..</param>
 /// <param name="transactionToPortfolioRate">The exchange rate between the transaction and portfolio currency. For example if the transaction currency is in USD and the portfolio currency is in GBP this this the USD/GBP rate..</param>
 /// <param name="transactionCurrency">The transaction currency..</param>
 /// <param name="properties">Set of unique transaction properties and associated values to stored with the transaction. Each property will be from the &#39;Transaction&#39; domain..</param>
 /// <param name="counterpartyId">The identifier for the counterparty of the transaction..</param>
 /// <param name="source">The source of the transaction. This is used to look up the appropriate transaction group set in the transaction type configuration..</param>
 /// <param name="transactionStatus">The status of the transaction. The available values are: Active, Amended, Cancelled.</param>
 /// <param name="entryDateTime">The asAt datetime that the transaction was added to LUSID..</param>
 /// <param name="cancelDateTime">If the transaction has been cancelled, the asAt datetime that the transaction was cancelled..</param>
 /// <param name="realisedGainLoss">The collection of realised gains or losses resulting from relevant transactions e.g. a sale transaction. The cost used in calculating the realised gain or loss is determined by the accounting method defined when the transaction portfolio is created..</param>
 public OutputTransaction(string transactionId = default(string), string type = default(string), string description = default(string), Dictionary <string, string> instrumentIdentifiers = default(Dictionary <string, string>), string instrumentScope = default(string), string instrumentUid = default(string), DateTimeOffset transactionDate = default(DateTimeOffset), DateTimeOffset settlementDate = default(DateTimeOffset), decimal units = default(decimal), decimal transactionAmount = default(decimal), TransactionPrice transactionPrice = default(TransactionPrice), CurrencyAndAmount totalConsideration = default(CurrencyAndAmount), decimal exchangeRate = default(decimal), decimal?transactionToPortfolioRate = default(decimal?), string transactionCurrency = default(string), Dictionary <string, PerpetualProperty> properties = default(Dictionary <string, PerpetualProperty>), string counterpartyId = default(string), string source = default(string), TransactionStatusEnum?transactionStatus = default(TransactionStatusEnum?), DateTimeOffset entryDateTime = default(DateTimeOffset), DateTimeOffset?cancelDateTime = default(DateTimeOffset?), List <RealisedGainLoss> realisedGainLoss = default(List <RealisedGainLoss>))
 {
     // to ensure "transactionId" is required (not null)
     this.TransactionId = transactionId ?? throw new ArgumentNullException("transactionId is a required property for OutputTransaction and cannot be null");
     // to ensure "type" is required (not null)
     this.Type = type ?? throw new ArgumentNullException("type is a required property for OutputTransaction and cannot be null");
     // to ensure "instrumentUid" is required (not null)
     this.InstrumentUid              = instrumentUid ?? throw new ArgumentNullException("instrumentUid is a required property for OutputTransaction and cannot be null");
     this.TransactionDate            = transactionDate;
     this.SettlementDate             = settlementDate;
     this.Units                      = units;
     this.Description                = description;
     this.InstrumentIdentifiers      = instrumentIdentifiers;
     this.InstrumentScope            = instrumentScope;
     this.TransactionAmount          = transactionAmount;
     this.TransactionPrice           = transactionPrice;
     this.TotalConsideration         = totalConsideration;
     this.ExchangeRate               = exchangeRate;
     this.TransactionToPortfolioRate = transactionToPortfolioRate;
     this.TransactionCurrency        = transactionCurrency;
     this.Properties                 = properties;
     this.CounterpartyId             = counterpartyId;
     this.Source                     = source;
     this.TransactionStatus          = transactionStatus;
     this.EntryDateTime              = entryDateTime;
     this.CancelDateTime             = cancelDateTime;
     this.RealisedGainLoss           = realisedGainLoss;
 }
示例#10
0
 /// <summary>
 /// Initializes a new instance of the <see cref="OrderRequest" /> class.
 /// </summary>
 /// <param name="properties">Client-defined properties associated with this order..</param>
 /// <param name="instrumentIdentifiers">The instrument ordered. (required).</param>
 /// <param name="quantity">The quantity of given instrument ordered. (required).</param>
 /// <param name="side">The client&#39;s representation of the order&#39;s side (buy, sell, short, etc) (required).</param>
 /// <param name="orderBookId">orderBookId.</param>
 /// <param name="portfolioId">portfolioId (required).</param>
 /// <param name="id">id (required).</param>
 /// <param name="state">The order&#39;s state (examples: New, PartiallyFilled, ...).</param>
 /// <param name="type">The order&#39;s type (examples: Limit, Market, ...).</param>
 /// <param name="timeInForce">The order&#39;s time in force (examples: Day, GoodTilCancel, ...).</param>
 /// <param name="date">The date on which the order was made.</param>
 /// <param name="price">price.</param>
 /// <param name="orderInstruction">orderInstruction.</param>
 /// <param name="package">package.</param>
 public OrderRequest(Dictionary <string, PerpetualProperty> properties = default(Dictionary <string, PerpetualProperty>), Dictionary <string, string> instrumentIdentifiers = default(Dictionary <string, string>), int quantity = default(int), string side = default(string), ResourceId orderBookId = default(ResourceId), ResourceId portfolioId = default(ResourceId), ResourceId id = default(ResourceId), string state = default(string), string type = default(string), string timeInForce = default(string), DateTimeOffset date = default(DateTimeOffset), CurrencyAndAmount price = default(CurrencyAndAmount), ResourceId orderInstruction = default(ResourceId), ResourceId package = default(ResourceId))
 {
     // to ensure "instrumentIdentifiers" is required (not null)
     this.InstrumentIdentifiers = instrumentIdentifiers ?? throw new ArgumentNullException("instrumentIdentifiers is a required property for OrderRequest and cannot be null");
     this.Quantity = quantity;
     // to ensure "side" is required (not null)
     this.Side = side ?? throw new ArgumentNullException("side is a required property for OrderRequest and cannot be null");
     // to ensure "portfolioId" is required (not null)
     this.PortfolioId = portfolioId ?? throw new ArgumentNullException("portfolioId is a required property for OrderRequest and cannot be null");
     // to ensure "id" is required (not null)
     this.Id               = id ?? throw new ArgumentNullException("id is a required property for OrderRequest and cannot be null");
     this.Properties       = properties;
     this.OrderBookId      = orderBookId;
     this.State            = state;
     this.Type             = type;
     this.TimeInForce      = timeInForce;
     this.Date             = date;
     this.Price            = price;
     this.OrderInstruction = orderInstruction;
     this.Package          = package;
 }
示例#11
0
 /// <summary>
 /// Initializes a new instance of the <see cref="TransactionRequest" /> class.
 /// </summary>
 /// <param name="transactionId">The unique identifier of the transaction. (required).</param>
 /// <param name="type">The type of the transaction, for example &#39;Buy&#39; or &#39;Sell&#39;. The transaction type must have been pre-configured using the System Configuration API. If not, this operation will succeed but you are not able to calculate holdings for the portfolio that include this transaction. (required).</param>
 /// <param name="instrumentIdentifiers">A set of instrument identifiers that can resolve the transaction to a unique instrument. (required).</param>
 /// <param name="transactionDate">The date of the transaction. (required).</param>
 /// <param name="settlementDate">The settlement date of the transaction. (required).</param>
 /// <param name="units">The number of units of the transacted instrument. (required).</param>
 /// <param name="transactionPrice">transactionPrice.</param>
 /// <param name="totalConsideration">totalConsideration (required).</param>
 /// <param name="exchangeRate">The exchange rate between the transaction and settlement currency (settlement currency being represented by TotalConsideration.Currency). For example, if the transaction currency is USD and the settlement currency is GBP, this would be the appropriate USD/GBP rate..</param>
 /// <param name="transactionCurrency">The transaction currency..</param>
 /// <param name="properties">A list of unique transaction properties and associated values to store for the transaction. Each property must be from the &#39;Transaction&#39; domain..</param>
 /// <param name="counterpartyId">The identifier for the counterparty of the transaction..</param>
 /// <param name="source">The source of the transaction. This is used to look up the appropriate transaction group set in the transaction type configuration..</param>
 /// <param name="otcConfirmation">otcConfirmation.</param>
 public TransactionRequest(string transactionId = default(string), string type = default(string), Dictionary <string, string> instrumentIdentifiers = default(Dictionary <string, string>), DateTimeOrCutLabel transactionDate = default(DateTimeOrCutLabel), DateTimeOrCutLabel settlementDate = default(DateTimeOrCutLabel), decimal units = default(decimal), TransactionPrice transactionPrice = default(TransactionPrice), CurrencyAndAmount totalConsideration = default(CurrencyAndAmount), decimal?exchangeRate = default(decimal?), string transactionCurrency = default(string), Dictionary <string, PerpetualProperty> properties = default(Dictionary <string, PerpetualProperty>), string counterpartyId = default(string), string source = default(string), OtcConfirmation otcConfirmation = default(OtcConfirmation))
 {
     // to ensure "transactionId" is required (not null)
     this.TransactionId = transactionId ?? throw new ArgumentNullException("transactionId is a required property for TransactionRequest and cannot be null");
     // to ensure "type" is required (not null)
     this.Type = type ?? throw new ArgumentNullException("type is a required property for TransactionRequest and cannot be null");
     // to ensure "instrumentIdentifiers" is required (not null)
     this.InstrumentIdentifiers = instrumentIdentifiers ?? throw new ArgumentNullException("instrumentIdentifiers is a required property for TransactionRequest and cannot be null");
     // to ensure "transactionDate" is required (not null)
     this.TransactionDate = transactionDate ?? throw new ArgumentNullException("transactionDate is a required property for TransactionRequest and cannot be null");
     // to ensure "settlementDate" is required (not null)
     this.SettlementDate = settlementDate ?? throw new ArgumentNullException("settlementDate is a required property for TransactionRequest and cannot be null");
     this.Units          = units;
     // to ensure "totalConsideration" is required (not null)
     this.TotalConsideration  = totalConsideration ?? throw new ArgumentNullException("totalConsideration is a required property for TransactionRequest and cannot be null");
     this.TransactionPrice    = transactionPrice;
     this.ExchangeRate        = exchangeRate;
     this.TransactionCurrency = transactionCurrency;
     this.Properties          = properties;
     this.CounterpartyId      = counterpartyId;
     this.Source          = source;
     this.OtcConfirmation = otcConfirmation;
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="ReconciliationBreak" /> class.
 /// </summary>
 /// <param name="instrumentScope">The scope in which the instrument lies..</param>
 /// <param name="instrumentUid">Unique instrument identifier (required).</param>
 /// <param name="subHoldingKeys">Any other properties that comprise the Sub-Holding Key (required).</param>
 /// <param name="leftUnits">Units from the left hand side (required).</param>
 /// <param name="rightUnits">Units from the right hand side (required).</param>
 /// <param name="differenceUnits">Difference in units (required).</param>
 /// <param name="leftCost">leftCost (required).</param>
 /// <param name="rightCost">rightCost (required).</param>
 /// <param name="differenceCost">differenceCost (required).</param>
 /// <param name="instrumentProperties">Additional features relating to the instrument (required).</param>
 public ReconciliationBreak(string instrumentScope = default(string), string instrumentUid = default(string), Dictionary <string, PerpetualProperty> subHoldingKeys = default(Dictionary <string, PerpetualProperty>), decimal leftUnits = default(decimal), decimal rightUnits = default(decimal), decimal differenceUnits = default(decimal), CurrencyAndAmount leftCost = default(CurrencyAndAmount), CurrencyAndAmount rightCost = default(CurrencyAndAmount), CurrencyAndAmount differenceCost = default(CurrencyAndAmount), List <Property> instrumentProperties = default(List <Property>))
 {
     // to ensure "instrumentUid" is required (not null)
     this.InstrumentUid = instrumentUid ?? throw new ArgumentNullException("instrumentUid is a required property for ReconciliationBreak and cannot be null");
     // to ensure "subHoldingKeys" is required (not null)
     this.SubHoldingKeys  = subHoldingKeys ?? throw new ArgumentNullException("subHoldingKeys is a required property for ReconciliationBreak and cannot be null");
     this.LeftUnits       = leftUnits;
     this.RightUnits      = rightUnits;
     this.DifferenceUnits = differenceUnits;
     // to ensure "leftCost" is required (not null)
     this.LeftCost = leftCost ?? throw new ArgumentNullException("leftCost is a required property for ReconciliationBreak and cannot be null");
     // to ensure "rightCost" is required (not null)
     this.RightCost = rightCost ?? throw new ArgumentNullException("rightCost is a required property for ReconciliationBreak and cannot be null");
     // to ensure "differenceCost" is required (not null)
     this.DifferenceCost = differenceCost ?? throw new ArgumentNullException("differenceCost is a required property for ReconciliationBreak and cannot be null");
     // to ensure "instrumentProperties" is required (not null)
     this.InstrumentProperties = instrumentProperties ?? throw new ArgumentNullException("instrumentProperties is a required property for ReconciliationBreak and cannot be null");
     this.InstrumentScope      = instrumentScope;
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="PortfolioHolding" /> class.
 /// </summary>
 /// <param name="instrumentScope">The scope in which the holding&#39;s instrument is in..</param>
 /// <param name="instrumentUid">The unique Lusid Instrument Id (LUID) of the instrument that the holding is in. (required).</param>
 /// <param name="subHoldingKeys">The sub-holding properties which identify the holding. Each property will be from the &#39;Transaction&#39; domain. These are configured on a transaction portfolio..</param>
 /// <param name="properties">The properties which have been requested to be decorated onto the holding. These will be from the &#39;Instrument&#39; or &#39;Holding&#39; domain..</param>
 /// <param name="holdingType">The type of the holding e.g. Position, Balance, CashCommitment, Receivable, ForwardFX etc. (required).</param>
 /// <param name="units">The total number of units of the holding. (required).</param>
 /// <param name="settledUnits">The total number of settled units of the holding. (required).</param>
 /// <param name="cost">cost (required).</param>
 /// <param name="costPortfolioCcy">costPortfolioCcy (required).</param>
 /// <param name="transaction">transaction.</param>
 /// <param name="currency">The holding currency..</param>
 public PortfolioHolding(string instrumentScope = default(string), string instrumentUid = default(string), Dictionary <string, PerpetualProperty> subHoldingKeys = default(Dictionary <string, PerpetualProperty>), Dictionary <string, Property> properties = default(Dictionary <string, Property>), string holdingType = default(string), decimal units = default(decimal), decimal settledUnits = default(decimal), CurrencyAndAmount cost = default(CurrencyAndAmount), CurrencyAndAmount costPortfolioCcy = default(CurrencyAndAmount), Transaction transaction = default(Transaction), string currency = default(string))
 {
     // to ensure "instrumentUid" is required (not null)
     this.InstrumentUid = instrumentUid ?? throw new ArgumentNullException("instrumentUid is a required property for PortfolioHolding and cannot be null");
     // to ensure "holdingType" is required (not null)
     this.HoldingType  = holdingType ?? throw new ArgumentNullException("holdingType is a required property for PortfolioHolding and cannot be null");
     this.Units        = units;
     this.SettledUnits = settledUnits;
     // to ensure "cost" is required (not null)
     this.Cost = cost ?? throw new ArgumentNullException("cost is a required property for PortfolioHolding and cannot be null");
     // to ensure "costPortfolioCcy" is required (not null)
     this.CostPortfolioCcy = costPortfolioCcy ?? throw new ArgumentNullException("costPortfolioCcy is a required property for PortfolioHolding and cannot be null");
     this.InstrumentScope  = instrumentScope;
     this.SubHoldingKeys   = subHoldingKeys;
     this.Properties       = properties;
     this.Transaction      = transaction;
     this.Currency         = currency;
 }
示例#14
0
 /// <summary>
 /// Initializes a new instance of the <see cref="RealisedGainLoss" /> class.
 /// </summary>
 /// <param name="instrumentScope">The scope in which the instrument lies..</param>
 /// <param name="instrumentUid">The unqiue Lusid Instrument Id (LUID) of the instrument that this gain or loss is associated with. (required).</param>
 /// <param name="units">The number of units of the associated instrument against which the gain or loss has been realised. (required).</param>
 /// <param name="purchasePrice">The purchase price of each unit associated with this gain or loss..</param>
 /// <param name="costTradeCcy">costTradeCcy (required).</param>
 /// <param name="costPortfolioCcy">costPortfolioCcy (required).</param>
 /// <param name="realisedTradeCcy">realisedTradeCcy (required).</param>
 /// <param name="realisedTotal">realisedTotal (required).</param>
 /// <param name="realisedMarket">realisedMarket.</param>
 /// <param name="realisedCurrency">realisedCurrency.</param>
 public RealisedGainLoss(string instrumentScope = default(string), string instrumentUid = default(string), decimal units = default(decimal), decimal?purchasePrice = default(decimal?), CurrencyAndAmount costTradeCcy = default(CurrencyAndAmount), CurrencyAndAmount costPortfolioCcy = default(CurrencyAndAmount), CurrencyAndAmount realisedTradeCcy = default(CurrencyAndAmount), CurrencyAndAmount realisedTotal = default(CurrencyAndAmount), CurrencyAndAmount realisedMarket = default(CurrencyAndAmount), CurrencyAndAmount realisedCurrency = default(CurrencyAndAmount))
 {
     // to ensure "instrumentUid" is required (not null)
     this.InstrumentUid = instrumentUid ?? throw new ArgumentNullException("instrumentUid is a required property for RealisedGainLoss and cannot be null");
     this.Units         = units;
     // to ensure "costTradeCcy" is required (not null)
     this.CostTradeCcy = costTradeCcy ?? throw new ArgumentNullException("costTradeCcy is a required property for RealisedGainLoss and cannot be null");
     // to ensure "costPortfolioCcy" is required (not null)
     this.CostPortfolioCcy = costPortfolioCcy ?? throw new ArgumentNullException("costPortfolioCcy is a required property for RealisedGainLoss and cannot be null");
     // to ensure "realisedTradeCcy" is required (not null)
     this.RealisedTradeCcy = realisedTradeCcy ?? throw new ArgumentNullException("realisedTradeCcy is a required property for RealisedGainLoss and cannot be null");
     // to ensure "realisedTotal" is required (not null)
     this.RealisedTotal    = realisedTotal ?? throw new ArgumentNullException("realisedTotal is a required property for RealisedGainLoss and cannot be null");
     this.InstrumentScope  = instrumentScope;
     this.PurchasePrice    = purchasePrice;
     this.RealisedMarket   = realisedMarket;
     this.RealisedCurrency = realisedCurrency;
 }
示例#15
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Transaction" /> class.
 /// </summary>
 /// <param name="transactionId">The unique identifier for the transaction. (required).</param>
 /// <param name="type">The type of the transaction e.g. &#39;Buy&#39;, &#39;Sell&#39;. The transaction type should have been pre-configured via the System Configuration API endpoint. (required).</param>
 /// <param name="instrumentIdentifiers">A set of instrument identifiers that can resolve the transaction to a unique instrument..</param>
 /// <param name="instrumentScope">The scope in which the transaction&#39;s instrument lies..</param>
 /// <param name="instrumentUid">The unqiue Lusid Instrument Id (LUID) of the instrument that the transaction is in. (required).</param>
 /// <param name="transactionDate">The date of the transaction. (required).</param>
 /// <param name="settlementDate">The settlement date of the transaction. (required).</param>
 /// <param name="units">The number of units transacted in the associated instrument. (required).</param>
 /// <param name="transactionPrice">transactionPrice.</param>
 /// <param name="totalConsideration">totalConsideration (required).</param>
 /// <param name="exchangeRate">The exchange rate between the transaction and settlement currency (settlement currency being represented by the TotalConsideration.Currency). For example if the transaction currency is in USD and the settlement currency is in GBP this this the USD/GBP rate..</param>
 /// <param name="transactionCurrency">The transaction currency..</param>
 /// <param name="properties">Set of unique transaction properties and associated values to stored with the transaction. Each property will be from the &#39;Transaction&#39; domain..</param>
 /// <param name="counterpartyId">The identifier for the counterparty of the transaction..</param>
 /// <param name="source">The source of the transaction. This is used to look up the appropriate transaction group set in the transaction type configuration..</param>
 /// <param name="entryDateTime">The asAt datetime that the transaction was added to LUSID..</param>
 /// <param name="otcConfirmation">otcConfirmation.</param>
 /// <param name="transactionStatus">The status of the transaction. The available values are: Active, Amended, Cancelled.</param>
 /// <param name="cancelDateTime">If the transaction has been cancelled, the asAt datetime that the transaction was cancelled..</param>
 public Transaction(string transactionId = default(string), string type = default(string), Dictionary <string, string> instrumentIdentifiers = default(Dictionary <string, string>), string instrumentScope = default(string), string instrumentUid = default(string), DateTimeOffset transactionDate = default(DateTimeOffset), DateTimeOffset settlementDate = default(DateTimeOffset), decimal units = default(decimal), TransactionPrice transactionPrice = default(TransactionPrice), CurrencyAndAmount totalConsideration = default(CurrencyAndAmount), decimal?exchangeRate = default(decimal?), string transactionCurrency = default(string), Dictionary <string, PerpetualProperty> properties = default(Dictionary <string, PerpetualProperty>), string counterpartyId = default(string), string source = default(string), DateTimeOffset entryDateTime = default(DateTimeOffset), OtcConfirmation otcConfirmation = default(OtcConfirmation), TransactionStatusEnum?transactionStatus = default(TransactionStatusEnum?), DateTimeOffset?cancelDateTime = default(DateTimeOffset?))
 {
     // to ensure "transactionId" is required (not null)
     this.TransactionId = transactionId ?? throw new ArgumentNullException("transactionId is a required property for Transaction and cannot be null");
     // to ensure "type" is required (not null)
     this.Type = type ?? throw new ArgumentNullException("type is a required property for Transaction and cannot be null");
     // to ensure "instrumentUid" is required (not null)
     this.InstrumentUid   = instrumentUid ?? throw new ArgumentNullException("instrumentUid is a required property for Transaction and cannot be null");
     this.TransactionDate = transactionDate;
     this.SettlementDate  = settlementDate;
     this.Units           = units;
     // to ensure "totalConsideration" is required (not null)
     this.TotalConsideration    = totalConsideration ?? throw new ArgumentNullException("totalConsideration is a required property for Transaction and cannot be null");
     this.InstrumentIdentifiers = instrumentIdentifiers;
     this.InstrumentScope       = instrumentScope;
     this.TransactionPrice      = transactionPrice;
     this.ExchangeRate          = exchangeRate;
     this.TransactionCurrency   = transactionCurrency;
     this.Properties            = properties;
     this.CounterpartyId        = counterpartyId;
     this.Source            = source;
     this.EntryDateTime     = entryDateTime;
     this.OtcConfirmation   = otcConfirmation;
     this.TransactionStatus = transactionStatus;
     this.CancelDateTime    = cancelDateTime;
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="OutputTransaction" /> class.
 /// </summary>
 /// <param name="instrumentIdentifiers">The set of instrument identifiers that can be used to resolve the transaction to a unique instrument..</param>
 /// <param name="transactionPrice">transactionPrice.</param>
 /// <param name="totalConsideration">totalConsideration.</param>
 public OutputTransaction(Dictionary <string, string> instrumentIdentifiers = default(Dictionary <string, string>), TransactionPrice transactionPrice = default(TransactionPrice), CurrencyAndAmount totalConsideration = default(CurrencyAndAmount))
 {
     this.InstrumentIdentifiers = instrumentIdentifiers;
     this.TransactionPrice      = transactionPrice;
     this.TotalConsideration    = totalConsideration;
 }
示例#17
0
        /// <summary>
        /// Initializes a new instance of the <see cref="PortfolioCashFlow" /> class.
        /// </summary>
        /// <param name="groupById">The groupBy subHoldings and currency. (required).</param>
        /// <param name="sequenceNumber">Sequence number determining the order of the cash flow records. (required).</param>
        /// <param name="effectiveDate">Indicates the date when the cash-flow settles..</param>
        /// <param name="subHoldingKeys">The sub-holding properties which identify the holding. Each property will be from the &#39;Transaction&#39; domain. These are configured when a transaction portfolio is created..</param>
        /// <param name="type">Indicates the record type (Closed, Open, Activity). (required).</param>
        /// <param name="movementName">Indicates the specific movement of the transaction that generated this cash flow. (required).</param>
        /// <param name="cashflow">cashflow (required).</param>
        /// <param name="balance">balance (required).</param>
        /// <param name="fxRate">Exchange rate between the currency of this cash flow and the reporting currency. (required).</param>
        /// <param name="cashflowReportingCurrency">cashflowReportingCurrency (required).</param>
        /// <param name="balanceReportingCurrency">balanceReportingCurrency (required).</param>
        /// <param name="translationGainLoss">translationGainLoss (required).</param>
        /// <param name="costBasisReportingCurrency">costBasisReportingCurrency (required).</param>
        /// <param name="transaction">transaction.</param>
        /// <param name="links">links.</param>
        public PortfolioCashFlow(int?groupById = default(int?), int?sequenceNumber = default(int?), DateTimeOffset?effectiveDate = default(DateTimeOffset?), Dictionary <string, PerpetualProperty> subHoldingKeys = default(Dictionary <string, PerpetualProperty>), string type = default(string), string movementName = default(string), CurrencyAndAmount cashflow = default(CurrencyAndAmount), CurrencyAndAmount balance = default(CurrencyAndAmount), decimal?fxRate = default(decimal?), CurrencyAndAmount cashflowReportingCurrency = default(CurrencyAndAmount), CurrencyAndAmount balanceReportingCurrency = default(CurrencyAndAmount), CurrencyAndAmount translationGainLoss = default(CurrencyAndAmount), CurrencyAndAmount costBasisReportingCurrency = default(CurrencyAndAmount), Transaction transaction = default(Transaction), List <Link> links = default(List <Link>))
        {
            // to ensure "groupById" is required (not null)
            if (groupById == null)
            {
                throw new InvalidDataException("groupById is a required property for PortfolioCashFlow and cannot be null");
            }
            else
            {
                this.GroupById = groupById;
            }

            // to ensure "sequenceNumber" is required (not null)
            if (sequenceNumber == null)
            {
                throw new InvalidDataException("sequenceNumber is a required property for PortfolioCashFlow and cannot be null");
            }
            else
            {
                this.SequenceNumber = sequenceNumber;
            }

            this.SubHoldingKeys = subHoldingKeys;
            // to ensure "type" is required (not null)
            if (type == null)
            {
                throw new InvalidDataException("type is a required property for PortfolioCashFlow and cannot be null");
            }
            else
            {
                this.Type = type;
            }

            // to ensure "movementName" is required (not null)
            if (movementName == null)
            {
                throw new InvalidDataException("movementName is a required property for PortfolioCashFlow and cannot be null");
            }
            else
            {
                this.MovementName = movementName;
            }

            // to ensure "cashflow" is required (not null)
            if (cashflow == null)
            {
                throw new InvalidDataException("cashflow is a required property for PortfolioCashFlow and cannot be null");
            }
            else
            {
                this.Cashflow = cashflow;
            }

            // to ensure "balance" is required (not null)
            if (balance == null)
            {
                throw new InvalidDataException("balance is a required property for PortfolioCashFlow and cannot be null");
            }
            else
            {
                this.Balance = balance;
            }

            // to ensure "fxRate" is required (not null)
            if (fxRate == null)
            {
                throw new InvalidDataException("fxRate is a required property for PortfolioCashFlow and cannot be null");
            }
            else
            {
                this.FxRate = fxRate;
            }

            // to ensure "cashflowReportingCurrency" is required (not null)
            if (cashflowReportingCurrency == null)
            {
                throw new InvalidDataException("cashflowReportingCurrency is a required property for PortfolioCashFlow and cannot be null");
            }
            else
            {
                this.CashflowReportingCurrency = cashflowReportingCurrency;
            }

            // to ensure "balanceReportingCurrency" is required (not null)
            if (balanceReportingCurrency == null)
            {
                throw new InvalidDataException("balanceReportingCurrency is a required property for PortfolioCashFlow and cannot be null");
            }
            else
            {
                this.BalanceReportingCurrency = balanceReportingCurrency;
            }

            // to ensure "translationGainLoss" is required (not null)
            if (translationGainLoss == null)
            {
                throw new InvalidDataException("translationGainLoss is a required property for PortfolioCashFlow and cannot be null");
            }
            else
            {
                this.TranslationGainLoss = translationGainLoss;
            }

            // to ensure "costBasisReportingCurrency" is required (not null)
            if (costBasisReportingCurrency == null)
            {
                throw new InvalidDataException("costBasisReportingCurrency is a required property for PortfolioCashFlow and cannot be null");
            }
            else
            {
                this.CostBasisReportingCurrency = costBasisReportingCurrency;
            }

            this.Links          = links;
            this.EffectiveDate  = effectiveDate;
            this.SubHoldingKeys = subHoldingKeys;
            this.Transaction    = transaction;
            this.Links          = links;
        }
示例#18
0
 /// <summary>
 /// Initializes a new instance of the <see cref="PortfolioCashFlow" /> class.
 /// </summary>
 /// <param name="groupById">The groupBy subHoldings and currency. (required).</param>
 /// <param name="sequenceNumber">Sequence number determining the order of the cash flow records. (required).</param>
 /// <param name="effectiveDate">Indicates the date when the cash-flow settles..</param>
 /// <param name="subHoldingKeys">The sub-holding properties which identify the holding. Each property will be from the &#39;Transaction&#39; domain. These are configured on a transaction portfolio..</param>
 /// <param name="type">Indicates the record type (Closed, Open, Activity). (required).</param>
 /// <param name="movementName">Indicates the specific movement of the transaction that generated this cash flow. (required).</param>
 /// <param name="cashflow">cashflow (required).</param>
 /// <param name="balance">balance (required).</param>
 /// <param name="fxRate">Exchange rate between the currency of this cash flow and the reporting currency. (required).</param>
 /// <param name="cashflowReportingCurrency">cashflowReportingCurrency (required).</param>
 /// <param name="balanceReportingCurrency">balanceReportingCurrency (required).</param>
 /// <param name="translationGainLoss">translationGainLoss (required).</param>
 /// <param name="costBasisReportingCurrency">costBasisReportingCurrency (required).</param>
 /// <param name="transaction">transaction.</param>
 /// <param name="unrealisedGainLossReportingCurrency">unrealisedGainLossReportingCurrency (required).</param>
 /// <param name="links">Collection of links..</param>
 public PortfolioCashFlow(int groupById = default(int), int sequenceNumber = default(int), DateTimeOffset effectiveDate = default(DateTimeOffset), Dictionary <string, PerpetualProperty> subHoldingKeys = default(Dictionary <string, PerpetualProperty>), string type = default(string), string movementName = default(string), CurrencyAndAmount cashflow = default(CurrencyAndAmount), CurrencyAndAmount balance = default(CurrencyAndAmount), decimal fxRate = default(decimal), CurrencyAndAmount cashflowReportingCurrency = default(CurrencyAndAmount), CurrencyAndAmount balanceReportingCurrency = default(CurrencyAndAmount), CurrencyAndAmount translationGainLoss = default(CurrencyAndAmount), CurrencyAndAmount costBasisReportingCurrency = default(CurrencyAndAmount), Transaction transaction = default(Transaction), CurrencyAndAmount unrealisedGainLossReportingCurrency = default(CurrencyAndAmount), List <Link> links = default(List <Link>))
 {
     this.GroupById      = groupById;
     this.SequenceNumber = sequenceNumber;
     // to ensure "type" is required (not null)
     this.Type = type ?? throw new ArgumentNullException("type is a required property for PortfolioCashFlow and cannot be null");
     // to ensure "movementName" is required (not null)
     this.MovementName = movementName ?? throw new ArgumentNullException("movementName is a required property for PortfolioCashFlow and cannot be null");
     // to ensure "cashflow" is required (not null)
     this.Cashflow = cashflow ?? throw new ArgumentNullException("cashflow is a required property for PortfolioCashFlow and cannot be null");
     // to ensure "balance" is required (not null)
     this.Balance = balance ?? throw new ArgumentNullException("balance is a required property for PortfolioCashFlow and cannot be null");
     this.FxRate  = fxRate;
     // to ensure "cashflowReportingCurrency" is required (not null)
     this.CashflowReportingCurrency = cashflowReportingCurrency ?? throw new ArgumentNullException("cashflowReportingCurrency is a required property for PortfolioCashFlow and cannot be null");
     // to ensure "balanceReportingCurrency" is required (not null)
     this.BalanceReportingCurrency = balanceReportingCurrency ?? throw new ArgumentNullException("balanceReportingCurrency is a required property for PortfolioCashFlow and cannot be null");
     // to ensure "translationGainLoss" is required (not null)
     this.TranslationGainLoss = translationGainLoss ?? throw new ArgumentNullException("translationGainLoss is a required property for PortfolioCashFlow and cannot be null");
     // to ensure "costBasisReportingCurrency" is required (not null)
     this.CostBasisReportingCurrency = costBasisReportingCurrency ?? throw new ArgumentNullException("costBasisReportingCurrency is a required property for PortfolioCashFlow and cannot be null");
     // to ensure "unrealisedGainLossReportingCurrency" is required (not null)
     this.UnrealisedGainLossReportingCurrency = unrealisedGainLossReportingCurrency ?? throw new ArgumentNullException("unrealisedGainLossReportingCurrency is a required property for PortfolioCashFlow and cannot be null");
     this.EffectiveDate  = effectiveDate;
     this.SubHoldingKeys = subHoldingKeys;
     this.Transaction    = transaction;
     this.Links          = links;
 }