C# 클래스 NContext.Extensions.Logging.Targets.BatchLogTargetBase

Defines a log target abstraction which supports batching.
상속: ILogTarget
파일 보기 프로젝트 열기: PowerDMS/NContext

공개 메소드들

메소드 설명
Complete ( ) : void

Signals to the T:System.Threading.Tasks.Dataflow.IDataflowBlock that it should not accept nor produce any more messages nor consume any more postponed messages.

Fault ( Exception exception ) : void

Causes the T:System.Threading.Tasks.Dataflow.IDataflowBlock to complete in a F:System.Threading.Tasks.TaskStatus.Faulted state.

OfferMessage ( DataflowMessageHeader messageHeader, LogEntry messageValue, ISourceBlock source, System.Boolean consumeToAccept ) : DataflowMessageStatus

Offers the message.

ShouldLog ( LogEntry logEntry ) : System.Boolean

Predicate which determines whether or not the target instance should log this entry.

보호된 메소드들

메소드 설명
BatchLogTargetBase ( Int32 batchSize, System.TimeSpan flushInterval ) : System

Initializes a new instance of the BatchLogTargetBase class.

BatchLogTargetBase ( Int32 batchSize, System.TimeSpan flushInterval, Int32 maxDegreeOfParallelism ) : System

Initializes a new instance of the BatchLogTargetBase class.

Log ( IEnumerable logEntries ) : void

Logs the specified log entries.

비공개 메소드들

메소드 설명
FlushTimerCallback ( Object state ) : void

메소드 상세

BatchLogTargetBase() 보호된 메소드

Initializes a new instance of the BatchLogTargetBase class.
protected BatchLogTargetBase ( Int32 batchSize, System.TimeSpan flushInterval ) : System
batchSize System.Int32 Size of the log batch.
flushInterval System.TimeSpan /// The interval with which to initiate a batching operation even if the /// number of currently queued logs is less than the . ///
리턴 System

BatchLogTargetBase() 보호된 메소드

Initializes a new instance of the BatchLogTargetBase class.
protected BatchLogTargetBase ( Int32 batchSize, System.TimeSpan flushInterval, Int32 maxDegreeOfParallelism ) : System
batchSize System.Int32 Size of the log batch.
flushInterval System.TimeSpan The flush interval. /// The interval with which to initiate a batching operation even if the /// number of currently queued logs is less than the . ///
maxDegreeOfParallelism System.Int32 The max degree of parallelism the target instance will log batch entries (ie. method).
리턴 System

Complete() 공개 메소드

Signals to the T:System.Threading.Tasks.Dataflow.IDataflowBlock that it should not accept nor produce any more messages nor consume any more postponed messages.
public Complete ( ) : void
리턴 void

Fault() 공개 메소드

Causes the T:System.Threading.Tasks.Dataflow.IDataflowBlock to complete in a F:System.Threading.Tasks.TaskStatus.Faulted state.
public Fault ( Exception exception ) : void
exception System.Exception The that caused the faulting.
리턴 void

Log() 보호된 추상적인 메소드

Logs the specified log entries.
protected abstract Log ( IEnumerable logEntries ) : void
logEntries IEnumerable The log entries.
리턴 void

OfferMessage() 공개 메소드

Offers the message.
public OfferMessage ( DataflowMessageHeader messageHeader, LogEntry messageValue, ISourceBlock source, System.Boolean consumeToAccept ) : DataflowMessageStatus
messageHeader DataflowMessageHeader The message header.
messageValue LogEntry The message value.
source ISourceBlock The source.
consumeToAccept System.Boolean The consume to accept.
리턴 DataflowMessageStatus

ShouldLog() 공개 추상적인 메소드

Predicate which determines whether or not the target instance should log this entry.
public abstract ShouldLog ( LogEntry logEntry ) : System.Boolean
logEntry LogEntry The log entry.
리턴 System.Boolean