AggregateGraphLookupOptions.cs 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. /* Copyright 2016-present MongoDB Inc.
  2. *
  3. * Licensed under the Apache License, Version 2.0 (the "License");
  4. * you may not use this file except in compliance with the License.
  5. * You may obtain a copy of the License at
  6. *
  7. * http://www.apache.org/licenses/LICENSE-2.0
  8. *
  9. * Unless required by applicable law or agreed to in writing, software
  10. * distributed under the License is distributed on an "AS IS" BASIS,
  11. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12. * See the License for the specific language governing permissions and
  13. * limitations under the License.
  14. */
  15. using System.Collections.Generic;
  16. using MongoDB.Bson.Serialization;
  17. namespace MongoDB.Driver
  18. {
  19. /// <summary>
  20. /// Represents options for the GraphLookup method.
  21. /// </summary>
  22. /// <typeparam name="TFrom">The type of from documents.</typeparam>
  23. /// <typeparam name="TAsElement">The type of the as field elements.</typeparam>
  24. /// <typeparam name="TOutput">The type of the output documents.</typeparam>
  25. public class AggregateGraphLookupOptions<TFrom, TAsElement, TOutput>
  26. {
  27. /// <summary>
  28. /// Gets or sets the TAsElement serialzier.
  29. /// </summary>
  30. public IBsonSerializer<TAsElement> AsElementSerializer { get; set; }
  31. /// <summary>
  32. /// Gets or sets the TFrom serializer.
  33. /// </summary>
  34. public IBsonSerializer<TFrom> FromSerializer { get; set; }
  35. /// <summary>
  36. /// Gets or sets the maximum depth.
  37. /// </summary>
  38. public int? MaxDepth { get; set; }
  39. /// <summary>
  40. /// Gets or sets the output serializer.
  41. /// </summary>
  42. public IBsonSerializer<TOutput> OutputSerializer { get; set; }
  43. /// <summary>
  44. /// Gets the filter to restrict the search with.
  45. /// </summary>
  46. public FilterDefinition<TFrom> RestrictSearchWithMatch { get; set; }
  47. }
  48. }