public Task<Dictionary<string, object>> ExecuteFieldsAsync(ExecutionContext context, IObjectGraphType rootType, object source, Dictionary<string, Fields> fields) { return fields.ToDictionaryAsync<KeyValuePair<string, Fields>, string, ResolveFieldResult<object>, object>( pair => pair.Key, pair => ResolveFieldAsync(context, rootType, source, pair.Value)); }
public async Task<object> ExecuteFields(ExecutionContext context, ObjectGraphType rootType, object source, Dictionary<string, Fields> fields) { return await fields.ToDictionaryAsync( pair => pair.Key, pair => ResolveField(context, rootType, source, pair.Value)); }
private async Task<IReadOnlyDictionary<string, object>> ExecuteFields( ExecutionContext context, ObjectGraphType rootType, object source, Dictionary<string, IEnumerable<Field>> fields, List<ExecutionError> executionErrors ) { return await fields.ToDictionaryAsync( pair => pair.Key, pair => ResolveField( context, rootType, source, pair.Value, executionErrors ) ); }