Exemple #1
0
 private ProtobufQueryable(RuntimeTypeModel model, Stream source, QueryableOptions options, Expression <Func <TSource, int, bool> > whereClause)
 {
     _whereClause = whereClause;
     _options     = options;
     _source      = source;
     _model       = model;
 }
 public void SelectOneProperty(QueryableOptions options)
 {
     Measure(
         () => _model.DeserializeItems <Event>(_stream, options.PrefixStyle, 0).Select(e => e.OccuranceDate).All(td => true),
         () => _model.AsQueryable <Event>(_stream, options).Select(e => e.OccuranceDate).All(td => true)
         );
 }
 public void OfTypeCount(QueryableOptions options)
 {
     Measure(
         () => _model.DeserializeItems <Event>(_stream, options.PrefixStyle, 0).OfType <OrderPlacedEvent>().Count(),
         () => _model.AsQueryable <Event>(_stream, options).OfType <OrderPlacedEvent>().Count()
         );
 }
 public ProtoLinqEnumerable(RuntimeTypeModel model, QueryableOptions options, Stream source, Func <TSource, int, bool> @where, Func <TSource, int, TResult> selector)
 {
     _options  = options;
     _source   = source;
     _where    = @where;
     _selector = selector;
     _model    = model;
 }
        protected SearchBuilderBase(QueryableOptions <T> options)
        {
            if (options == null)
            {
                throw new ArgumentNullException(nameof(options));
            }

            this.Options = options;
        }
 public ProtoLinqAggregator(RuntimeTypeModel model, QueryableOptions options, Stream source, TAccumulate seed, Func <TSource, int, bool> @where, Func <TAccumulate, TSource, TAccumulate> func)
 {
     _source  = source;
     _seed    = seed;
     _where   = @where;
     _func    = func;
     _model   = model;
     _options = options;
 }
Exemple #7
0
 public ProtobufQueryable(RuntimeTypeModel model, Stream source, QueryableOptions options)
     : this(model, source, options, TrueWhereClauseNullObject)
 {
 }
 public ProtobufQueryableBuilder(RuntimeTypeModel model, Stream source, QueryableOptions options)
 {
     _model   = model;
     _source  = source;
     _options = options;
 }