PostSharp6.0/API Reference/Post­Sharp.​Patterns.​Diagnostics.​Record­Builders Namespace/Log­Record­Builder Class/Log­Record­Builder Methods

LogRecordBuilder Methods

The LogRecordBuilder type exposes the following members.

Methods
  NameDescription
Public methodBeginCustomRecord
Initializes the current LogRecordBuilder to emit a custom record.
Public methodBeginRecord
Initializes the current LogRecordBuilder to emit a standard (i.e. non-custom) record for a given context and method.
Public methodComplete
Emits the record and resets the current LogRecordBuilder. This method invoked after all SetThis<T>(T), SetParameter<T>(Int32, String, ParameterKind, String, T) and similar methods have been called.
Public methodDispose
Protected methodEmitRecord
Emits the record. Invoked by the Complete() method.
Protected methodReset
Resets all fields and properties of the current LogRecordBuilder to their initial value. Invoked by the Complete() method.
Public methodSetException
Sets the exception for the method or activity.
Public methodSetExecutionTime
Sets the method or activity execution time.
Public methodSetMethodGenericParameter<T>
Not implemented.
Public methodSetParameter<T>(Int32, String, ParameterKind, String, T)
Sets the value of a given parameter and uses the default formatter.
Public methodSetParameter<T>(Int32, String, ParameterKind, String, T, IFormatter<T>)
Sets the value of a given parameter and specifies the Formatter<T>.
Public methodSetRefStructParameter
Public methodSetReturnValue<T>(Int32, String, String, T)
Sets a given return value (there can be several return values in C# 7.0) and uses the default formatter.
Public methodSetReturnValue<T>(Int32, String, String, T, IFormatter<T>)
Sets a given return value (there can be several return values in C# 7.0) and uses a given formatter.
Public methodSetThis<T>(T)
Sets the this (instance) value and uses the default formatter. This method is only invoked if the IncludeThisValue property is true.
Public methodSetThis<T>(T, IFormatter<T>)
Sets the this (instance) value and uses a given formatter.
Public methodSetTypeGenericParameter<T>
Not implemented.
Public methodWriteCustomParameter<T>(Int32, ArraySegment<Char>, T)
Writes a custom parameter and uses the default formatter.
Public methodWriteCustomParameter<T>(Int32, ArraySegment<Char>, T, IFormatter<T>)
Writes a custom parameter and uses a given formatter.
Public methodWriteCustomString
Write a chunk of custom string.
See Also