LogCallHandler return value??

Topics: Logging Application Block, Policy Injection Application Block
Jan 29, 2009 at 12:26 AM
I would love to use the LogCallHandler for logging however it doesn't seem to log what the return value is for any given method, only the parameters passed to it.

Is there a special way to enable this functionality?

Jan 29, 2009 at 1:09 AM
I figured it out... not sure where the documentation on this is but after looking at the source code and trial and error, i figured out you can output properties of the TraceLogEntry object using this syntax in your formatter:


Example to output a return value and exception:

Timestamp: {timestamp}
Message: {message}
Method Parameters: {dictionary({key} - {value})}
Return Value: {property(ReturnValue)}
Exception: {property(Exception)}