Annotations and Validation

Tags:

Annotations and Validation

Validating annotations is discussed. Two problems are widely known: (1) annotation value can’t be null, (2) annotation doesn’t support inheritance. From some respect, these are trivial.

The important thing that the author tries to point out is that the annotation facility lacks validation mechanism. For example, XML is well formed, enabling parsing. However, what really makes XML useful is that XML documents can be shared after some verfications based on DTD or XSD. But, this is not happening in annotation world.

So, the bottom line is, “What will happen if one makes errors while annotating? How can we handle such and such predictable problems?”

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *