Skip to content

How to create a composite aspect, i.e. combining multiple aspects into a single one? #349

Closed Answered by gfraiteur
ziriax asked this question in Q&A
Discussion options

You must be logged in to vote

What we call composite aspects are aspects that combine several pieces of advice. This is covered in the conceptual documentation. Basically you need to implement the BuildAspect.

However in your specific case, your implementation of QueryAttribute.OverrideMethod must combine the logic of both aspects in a single template.

Another approach is to have QueryAttribute provide Log and Cache as child aspects.

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@ziriax
Comment options

Answer selected by gfraiteur
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants