簡體   English   中英

面向方面的C#編程庫(緊湊框架3.5)

[英]Aspect oriented programming library for C# (compact framework 3.5)

對支持緊湊框架版本3.5的C#面向方面的編程庫有何建議? 似乎PostSharp支持它,但是還有其他選擇嗎?

編輯:替代品? http://www.sharpcrafters.com/postsharp/alternatives,但我不知道它們是否支持CF。 由於大多數替代方案(.NET)使用代理/攔截,因此我認為它們不支持CF。

SharpCrafters的PostSharp。 http://www.sharpcrafters.com/postsharp/download

它確實支持CF 3.5。 如果您將Postsharp用於常規的.NET(如果有的話,您可能不會問這個問題),您會發現它確實有所不同。

http://doc.sharpcrafters.com/postsharp/2.0/##PostSharp.chm/html/695ec9f3-577a-4175-8cba-c00d0cb6e47c.htm

由於Silverlight或Compact Framework項目未鏈接到常規.NET Framework(mscorlib的公鑰,甚至其他系統程序集的名稱也不同),因此無法將這些項目生成的程序集加載到CLR中。

這有許多直接后果:

 *Aspects are not instantiated at build time by PostSharp. *Therefore, aspects are not serialized. *Compile-time semantics like CompileTimeValidate, 

不支持CompileTimeInitialize,IAspectBuildSemantics或IAspectProvider。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM