Beispiel #1
0
        // ** Equality

        protected bool Equals(MonthlyReturnSeries other)
        {
            if (!_monthlyReturns.SequenceEqual(other._monthlyReturns))
            {
                return(false);
            }

            return(ReturnSeriesId == other.ReturnSeriesId && Equals(FeeType, other.FeeType));
        }
Beispiel #2
0
        private MonthlyReturnSeries CreateReturnSeries(
            ReturnSeriesDto r)
        {
            var returnSeries = new MonthlyReturnSeries()
            {
                ReturnSeriesId = r.ReturnSeriesId,
                FeeType        = FeeType.FromCode(r.FeeTypeCode)
            };

            var returnsForSeries = _monthlyReturnDtos
                                   .Where(d => d.ReturnSeriesId == r.ReturnSeriesId);

            returnSeries.AddReturns(
                returnsForSeries.Select(CreateMonthlyReturn));

            return(returnSeries);
        }
Beispiel #3
0
 public void AddReturnSeries(
     MonthlyReturnSeries a)
 {
     _returnSeries.Add(a);
 }