First, I would like to criticize blogdriver's RSS. It seems that it has been lagging behind since it was acquired by BC. It often takes several days to see it update RSS, so I missed a lot of new gigixArticle, 874.
In the morning, I talked to Ling Hu about the annotation sucks in gigix's RSS feed "latest" (it has been nearly half a month-_-|). Both gigix and Robbin obviously oppose annotation. Robbin considers this to undermine the purity of Java, and gigix thinks this is not as flexible as XML.
The feature added in this Java is obviously learned from the. NET attribute. But Ling Hu and I thought this feature was good.
Ling Hu said:I liked it very much and thought that I put all the content in the expression.CodeThe code is not synchronized due to multiple modifications. It is also clear. However, gigix seems to make sense. That is, attribute. However, it seems that attribute is more radical because it has less burdens..
I think annotation is good in terms of performance. After all, the aspects that require annotation are rarely changed. And if it needs to be changed, the source code also needs to be changed accordingly.
Ling Hu also turned to a saying that he saw it in javaeye:Basically, there is no need to modify the XML instead of the Code..
I am paying attention to this issue because when I use Delphi to implement dynamic proxy to develop a Web framework, the business logic is implemented using BPL, the two intend to insert the login verification Section through the AOP method. But the difficulty is that not all page calls require verification. How can we differentiate them?
When
However, as gigix said, it can be described through external XML. However, if there is metadata such as attribute/annotation, I think it is a better solution.
Solution. After all, whether to verify itself is also part of the business logic. It is closely related to the Business Code. Separating it into external XML not only brings performance problems, but also has potential inconsistency risks, and
Flexibility is unnecessary.
Therefore, attribute/annotation is good.
BTW: to add, gigix annotation vs. Configuration
-- August 2