/// <summary> /// Adds a filter to this ResourceSetExpression. /// If filter is already presents, adds the predicateConjunts to the /// PredicateConjucts of the filter /// </summary> internal void AddFilter(IEnumerable <Expression> predicateConjuncts) { if (this.Skip != null) { throw new NotSupportedException(Strings.ALinq_QueryOptionOutOfOrder("filter", "skip")); } else if (this.Take != null) { throw new NotSupportedException(Strings.ALinq_QueryOptionOutOfOrder("filter", "top")); } else if (this.Projection != null) { throw new NotSupportedException(Strings.ALinq_QueryOptionOutOfOrder("filter", "select")); } if (this.Filter == null) { this.AddSequenceQueryOption(new FilterQueryOptionExpression(this.Type)); } this.Filter.AddPredicateConjuncts(predicateConjuncts); this.keyPredicateConjuncts.Clear(); }