Open sandboxFocus

Class NotLoggedAttribute

Indicates that the value of this parameter should not be logged.

Inheritance
NotLoggedAttribute
Namespace: PostSharp.Patterns.Diagnostics
Assembly: PostSharp.Patterns.Diagnostics.dll
Syntax
[AttributeUsage(AttributeTargets.Parameter|AttributeTargets.ReturnValue)]
public sealed class NotLoggedAttribute : Attribute
Remarks

Apply this attribute to a parameter, or to a return value with [return: NotLogged], of a method that is logged with LogAttribute. The log records then contain ******* instead of the value.

The values of parameters of type SecureString, and of parameters whose name contains password or pwd (case-insensitive), are hidden even without this attribute.

Constructors

Name Description
NotLoggedAttribute()

See Also