| Summary: | Some Javadoc and code clean up suggestions | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Product: | [WebTools] WTP Common Tools | Reporter: | Gary Karasiuk <karasiuk> | ||||||||||
| Component: | wst.common | Assignee: | Gary Karasiuk <karasiuk> | ||||||||||
| Status: | RESOLVED FIXED | QA Contact: | Carl Anderson <ccc> | ||||||||||
| Severity: | minor | ||||||||||||
| Priority: | P3 | CC: | shr31223 | ||||||||||
| Version: | 3.2.3 | Flags: | ccc:
review+
|
||||||||||
| Target Milestone: | 3.2.4 | ||||||||||||
| Hardware: | PC | ||||||||||||
| OS: | Windows XP | ||||||||||||
| Whiteboard: | |||||||||||||
| Attachments: |
|
||||||||||||
|
Description
Gary Karasiuk
Created attachment 190308 [details]
a patch to make the code more readable
Created attachment 190310 [details]
another small patch to improve the readability
Created attachment 190376 [details]
more cleanup
Please hold off applying this patch, as I may be adding some more to it.
But I wanted to attach the clean up that I have done so far, so that you would have a chance to see the types of things that I would like to change.
I am trying to remove some of the "clutter". For example, the Java spec says that all primitive fields in an Interface are public static final, so there is no need to add these modifiers.
Or when you are adding an int field to a class, the spec already says that it will be initialized to 0, so there is no need to add " = 0".
I've been checking if inner classes should be static or not. I've been adding final to the fields that should be final. And I have been adding new Javadoc, in particular I have been documenting the locking.
Created attachment 190413 [details]
final cleanup patch
Here are a set of changes, that makes the code more readable. Could you commit these please. The changes should cause not any behavioral changes.
I was reviewing this area of the code because of all the deadlocks. While this doesn't fix any of the deadlocks, I hope it makes the code a bit more understandable.
Patch released to 3.2.4 and HEAD. |