public StatisticsLogDecoratorTargetBatched(ITargetBatchedFunctor <TIn> decoratedTarget, ILogAgent logAgent) : base(logAgent, decoratedTarget.Title, DataflowNetworkConstituent.TargetBatched) { m_DecoratedTarget = decoratedTarget; // Can't tell, how many messages are broken Interlocked.Decrement(ref NumBrokenMessages); }
public WorkloadStatisticsDecoratorTargetBatched(Guid groupGuid, ZContext ctx, ITargetBatchedFunctor <TIn> decoratedTarget, int boundedCapacity, Func <int> inMsgFunc, CancellationToken ct) : base(groupGuid, ctx, DataflowNetworkConstituent.TargetBatched, boundedCapacity, ct) { m_DecoratedTarget = decoratedTarget; m_InMsgFunc = inMsgFunc; m_nms = 0; }
public static ITargetBatchedFunctor <TIn> WithStatistics <TIn>(this ITargetBatchedFunctor <TIn> decoratedTarget, ILogAgent logAgent) { return(new StatisticsLogDecoratorTargetBatched <TIn>(decoratedTarget, logAgent)); }
public static ITargetBatchedFunctor <TIn> WithWorkloadStatistics <TIn>(this ITargetBatchedFunctor <TIn> decoratedTarget, int boundedCapacity, Func <int> incMsgCnt, ZContext ctx, Guid groupguid, CancellationToken ct) { return(new WorkloadStatisticsDecoratorTargetBatched <TIn>(groupguid, ctx, decoratedTarget, boundedCapacity, incMsgCnt, ct)); }
public LogDecoratorTargetBatched(ITargetBatchedFunctor <TIn> decoratedTarget, ILogAgent logAgent) { m_DecoratedTarget = decoratedTarget; m_LogAgent = logAgent; }
public static Action <IDataflowMessage <TIn>[]> AsFunction <TIn>(this ITargetBatchedFunctor <TIn> target) { return(target.Push); }