Exemple #1
0
            protected override Task <IEnumerable <TElem> > Resolve(IResolveFieldContext context, IServiceProvider provider)
            {
                var resolver = provider.GetRequiredService <TResolver>();

                var args = context.DeserializeArgs <TArgs>();

                return(resolver.Resolve(args));
            }
Exemple #2
0
            protected override Task <TProp> Resolve(IResolveFieldContext context, IServiceProvider provider)
            {
                var resolver = provider.GetRequiredService <TResolver>();

                // apparently need to downcast the context to get deserialization
                var args = context.DeserializeArgs <TArgs>();

                return(resolver.Resolve(args));
            }