Documentation and modernization of the code #7
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
While I was scanning the code, I played with it and added some JavaDoc, and I also refactored the code a bit. There was some copy-paste in the code, many of which I eliminated by introducing a new interface and abstract classes. The code compiles and the unit tests run, but I am not easy because I have found certain errors I made (and later fixed) during refactoring that were not discovered by the unit tests. The line coverage is good, but that is not enough.
For example, if you look at the line
AbstractSpiProcessor:137
Removing the
!
character after thereturn
keyword is a significant change. The unit tests just run fine.I still see some abstraction and architectural issues in the code. For example,
writeData()
seems to be unnatural in the processor when there is aPersistence
class. I did not change that.Use this pull request as you like, partially or fully, or just throwing it out. I mainly did this to learn a bit from the code, and although I wrote a few annotation providers (two to be specific), I learned a lot from your code about annotation processors and coding. It was really refreshing to work on some code that is a good quality in the abstractions. Every day I review and fix code created by juniors or mediocre developers who do not care.