Пример #1
0
        /// <summary>
        /// Initializes a new instance of the <see cref="DistanceCriteria"/> class.
        /// </summary>
        /// <param name="field">Field that must be within the specified ranges.</param>
        /// <param name="member">Property or field that this range criteria applies to.</param>
        /// <param name="value">GeographyPoint for distance calculation</param>
        /// <param name="comparisonValue">ComparisonSpecificationCriteria that this criteria tests against.</param>
        public DistanceCriteria(string field, MemberInfo member, GeographyPoint value, ComparisonSpecificationCriteria comparisonValue)
        {
            Argument.EnsureNotBlank(nameof(field), field);
            Argument.EnsureNotNull(nameof(member), member);
            //Argument.EnsureNotNull(nameof(comparisonValue), comparisonValue);

            Field  = field;
            Member = member;
            CriteriaForComparison = comparisonValue;
            Value = value;
        }
Пример #2
0
 public void ReplaceComparison(Comparison comparison, object value)
 {
     CriteriaForComparison = new ComparisonSpecificationCriteria(comparison, value);
 }