PostSharp 6.6 / / Post­Sharp Documentation / API Reference / Post­Sharp.​Patterns.​Dynamic­Advising Namespace / Dynamic­Advising­Services Class / Dynamic­Advising­Services Methods / Dynamic­Advising­Services.​Query­Object Method

DynamicAdvisingServices.QueryObject Method

Gets the principal object of an advice.

Namespace:  PostSharp.Patterns.DynamicAdvising
Assembly:  PostSharp.Patterns.Common (in PostSharp.Patterns.Common.dll) Version: 6.6.14.0 (6.6.14.0)
Syntax
C#
public static Object QueryObject(
	Object obj
)

Parameters

obj
Type: System.Object
An object or a dynamic advice.

Return Value

Type: Object
The AdvisedObject is obj is a dynamic advice, otherwise obj itself.
See Also