MediateV.S EventHandler

最近看了一些wiz框架的例子,發現Mediate這個標籤用的比較多,只知道它的做用跟EventHandler是同樣的,可是二者有什麼區別,實在是沒搞明白。原覺得這個標籤功能更強悍,上網google了一把,才知道在SWIZ1.0以後更偏向用EventHandler,由於Mediate會讓人感到有些疑惑,並且不能很好的描述這個標籤的意圖,用EventHandler就明朗多了.如下是原話:框架

Mediate will continue to work since it has been around for so long, but it
is being deprecated in favor of the [EventHandler] metadata tag. We decided
that Mediate was just confusing and didn't describe the intent of the tag
very well. EventHandler makes it more obvious what the tag is doing.

ide

相關文章
相關標籤/搜索