Metalama 1.0 / / Metalama Documentation / Aspect API / Metalama.​Framework.​Aspects / IAspect­Builder / With­Target

Method WithTarget

WithTarget<T>(T)

Returns a copy of the current IAspectBuilder, for use in the current execution context, but for a different Target declaration.

Declaration
IAspectBuilder<T> WithTarget<T>(T newTarget)
where T : class, IDeclaration
Parameters
Type Name Description
T newTarget
Returns
Type Description
IAspectBuilder<T>
Type Parameters
Name Description
T