/src/LinFu.AOP/Interfaces/IHostWeaver.cs
http://github.com/philiplaureano/LinFu · C# · 23 lines · 9 code · 2 blank · 12 comment · 0 complexity · c92d11186b5c406e4394c50e388c7d5d MD5 · raw file
- using Mono.Cecil;
- namespace LinFu.AOP.Cecil.Interfaces
- {
- /// <summary>
- /// Represents a weaver class that can modify its host.
- /// </summary>
- /// <typeparam name="THost">The host that holds the item to be modified.</typeparam>
- public interface IHostWeaver<THost>
- {
- /// <summary>
- /// Imports references into the target <see cref="ModuleDefinition" /> instance.
- /// </summary>
- /// <param name="module">The module that will hold the modified item.</param>
- void ImportReferences(ModuleDefinition module);
- /// <summary>
- /// Adds additional members to the host type.
- /// </summary>
- /// <param name="host">The host that holds the current item being modified.</param>
- void AddAdditionalMembers(THost host);
- }
- }