コード例 #1
0
 public static async Task <T> ExecAsync <T>(this IHeap heap, HeapRequest <T> query, Guid idempotencyToken = default(Guid), INode node = null)
 => (await ExecResultAsync(heap, query, idempotencyToken, node)).GetResult().CastTo <T>();
コード例 #2
0
        public static async Task <SaveResult <object> > ExecResultAsync(this IHeap heap, HeapRequest query, Guid idempotencyToken = default(Guid), INode node = null)
        {
            var atr  = HeapAttribute.Lookup <HeapProcAttribute>(query.NonNull(nameof(query)).GetType());
            var area = heap.NonNull(nameof(heap))[atr.Area];

            return(await area.ExecuteAsync(query, idempotencyToken, node));
        }