Example #1
0
        public static Task <Option <TDto> > HandleReadOne(Option <TDto> criteria, Option <CancellationToken> ctok)
        {
            var @for = new Crud <T, TDto, TCrudInterceptor>();

            return(@for.Handler().ReduceOrDefault().Handle(new ReadOneRequest <T, TDto>(criteria), ctok));
        }
Example #2
0
        public static Task <Option <Dictionary <string, object> > > HandleUpdate(Option <TDto> dto, Option <CancellationToken> ctok)
        {
            var @for = new Crud <T, TDto, TCrudInterceptor>();

            return(@for.Handler().ReduceOrDefault().Handle(new UpdateRequest <T, TDto>(dto), ctok));
        }
Example #3
0
        public static Task <Option <List <KeyValue> > > HandleReadLookup(Option <bool> useValueAsId, Option <CancellationToken> ctok)
        {
            var @for = new Crud <T, TDto, TCrudInterceptor>();

            return(@for.Handler().ReduceOrDefault().Handle(new ReadLookupRequest <T, TDto>(useValueAsId), ctok));
        }