Spring.NET 1.3.0 RC1 for .NET 2.0 API Reference

DefaultAdvisorAdapterRegistry.Wrap Method

Returns an IAdvisor wrapping the supplied advice.

[Visual Basic]
Public Overridable Sub Wrap( _
   ByVal advice As Object _
) _
    Implements IAdvisorAdapterRegistry.Wrap
[C#]
public virtual IAdvisor Wrap(
   object advice
);

Parameters

advice
The object that should be an advice, such as IBeforeAdvice or IThrowsAdvice.

Return Value

An IAdvisor wrapping the supplied advice. Never returns . If the advice parameter is an IAdvisor, it will simply be returned.

Implements

IAdvisorAdapterRegistry.Wrap

Exceptions

Exception Type Condition
UnknownAdviceTypeException If no registered IAdvisorAdapter can wrap the supplied advice.

See Also

DefaultAdvisorAdapterRegistry Class | Spring.Aop.Framework.Adapter Namespace