예제 #1
0
        /// <summary>
        /// Initializes a new instance of the <see cref="AggregateResult"/> class.
        /// </summary>
        /// <param name="value">The value of the result.</param>
        /// <param name="count">The number of arguments used for the calculation of the result.</param>
        /// <param name="function">Function that generated the result.</param>
        /// <exception cref="ArgumentNullException"><c>function</c> is null.</exception>
        public AggregateResult(object value, int count, AggregateFunction function)
        {
            if (function == null)
            {
                throw new ArgumentNullException("function");
            }

            aggregateValue = value;
            itemCount = count;
            this.function = function;
        }
예제 #2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="AggregateResult"/> class.
 /// </summary>
 /// <param name="value">The value of the result.</param>
 /// <param name="function"><see cref="AggregateFunction"/> that generated the result.</param>
 public AggregateResult(object value, AggregateFunction function)
     : this(value, default(int), function)
 {
 }
예제 #3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="AggregateResult"/> class.
 /// </summary>
 /// <param name="function"><see cref="AggregateFunction"/> that generated the result.</param>
 /// <exception cref="ArgumentNullException"><c>function</c> is null.</exception>
 public AggregateResult(AggregateFunction function)
     : this(null, function)
 {
 }