Пример #1
0
        public ISchemaMerger AddDirectiveMergeRule(
            MergeDirectiveRuleFactory factory)
        {
            if (factory == null)
            {
                throw new ArgumentNullException(nameof(factory));
            }

            _directiveMergeRules.Add(factory);
            return(this);
        }
        /// <summary>
        /// Add a directive merge rule in order to define
        /// how a directive is merged.
        /// </summary>
        /// <param name="builder">
        /// The <see cref="IRequestExecutorBuilder"/>.
        /// </param>
        /// <param name="mergeRuleFactory">
        /// A factory that create the directive merging rule.
        /// </param>
        /// <returns>
        /// Returns the <see cref="IRequestExecutorBuilder"/>.
        /// </returns>
        /// <exception cref="ArgumentNullException">
        /// <paramref name="builder"/> is <c>null</c>, or
        /// <paramref name="mergeRuleFactory"/> is <c>null</c>.
        /// </exception>
        public static IRequestExecutorBuilder AddDirectiveMergeRule(
            this IRequestExecutorBuilder builder,
            MergeDirectiveRuleFactory mergeRuleFactory)
        {
            if (builder == null)
            {
                throw new ArgumentNullException(nameof(builder));
            }

            if (mergeRuleFactory == null)
            {
                throw new ArgumentNullException(nameof(mergeRuleFactory));
            }

            return(builder.ConfigureSchema(
                       s => s.AddDirectiveMergeRules(mergeRuleFactory)));
        }
 public IStitchingBuilder AddDirectiveMergeRule(MergeDirectiveRuleFactory factory)
 {
     throw new NotImplementedException();
 }