Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

AOP

Status
Not open for further replies.

B00gyeMan

Programmer
Jan 14, 2004
259
RO
Hi. This is a question concerning AOP and .NET.
Here it is: is it possible to implement AOP concepts in .NET without inheriting from ContextBoundObject? Because this is a huge limitation, in my opinion...
 
Hello,

Sorry for my ignorance but, what do you mean by "AOP concepts"

Thank you!

Polu.
 
Aspect Oriented Programming.

Basically, concerns that cross-cut many of your classes, that you don't want to code more than once. Examples are logging, auditing, trace, performance timing etc. AOP provides 'pointcuts' that allow you to hook in at certain execution points in your code, e.g. method invocation. You can then execute some common function like auditing or logging at this point without having to put the code in your classes.

Personally I think it's a great way to handle non-functional requirements (like the examples above) but I feel that attempting to use it as a way to 'bolt on' functional requirements after a system is built will lead to a maintenance nightmare.

HTH

Steve
 
Polu:
On the other hand, Stevexff is right about the maintenance, developing and debugging costs. Think that every method invocation is passed through a transparent proxy, a real proxy and a series of message sinks before the actual method code get executed...

I just was experimenting with the idea and found it interesting, except that every class needs to inherit ContextBoundObject, not to say the performance impact (due to context switches and the other operations described above).

Finally (after reading tons of articles written by both Microsoft people and thirt-parties) the conclusion is that the answer to my question is no...
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top