PostSharp 6.10 / / Post­Sharp Documentation / API Reference / Post­Sharp.​Patterns.​Diagnostics.​Custom Namespace / Logging­Properties­Expression­Model Structure

LoggingPropertiesExpressionModel Structure

Type of the t parameters for if and sample expressions in the policy configuration file.

Namespace:  PostSharp.Patterns.Diagnostics.Custom
Assembly:  PostSharp.Patterns.Common (in PostSharp.Patterns.Common.dll) Version: 6.10.10.0 (6.10.10.0)
Syntax
C#
public readonly struct LoggingPropertiesExpressionModel

The LoggingPropertiesExpressionModel type exposes the following members.

Properties
  NameDescription
Public propertyItem
Returns the value of the logging property with the given name, or null if there is no such logging property.
Methods
  NameDescription
Public methodContains
Returns true if a logging property with the given name exists.
Public methodGetInt32
Gets the value of a logging property as an Int32, or defaultValue if the property does not exist. Throws an exception if the property exists but can't be converted to Int32 using ToInt32(Object).
Public methodGetInt64
Gets the value of a logging property as an Int64, or defaultValue if the property does not exist. Throws an exception if the property exists but can't be converted to Int64 using ToInt64(Object).
Public methodGetString
Gets the value of a logging property as a string, or defaultValue if the property does not exist.
See Also