From: Glen K. <gl...@ho...> - 2000-12-12 18:04:42
|
>Also, I would assume that saving the result into an HTML file would be ok >not knowing all parties access to tools. FYI: Together software (www.togethersoft.com) offers a free product for creating Java class diagrams. _____________________________________________________________________________________ Get more from the Web. FREE MSN Explorer download : http://explorer.msn.com |
From: William G. <ww...@ts...> - 2000-12-14 15:49:58
|
Hi, Glen -- > FYI: Together software (www.togethersoft.com) offers a free product for > creating Java class diagrams. Together is a very nice tool. However, the free version doesn't do as much as the expensive versions: does it allow you to export to html (I can't remember ...)? I like Together, but I think that for the design doc, other tools are more suitable. It's a great tool for use by developers, though: if the rest of you haven't looked at it, follow Glen's link and try out the free version. It reverse engineers your code into class diagrams, also, which is cool to get a handle on someone else's code, etc. Regards, Bill G, |
From: William G. <ww...@ts...> - 2000-12-16 18:57:58
|
This is probably not complete, but let's get started deciding on this. Note: 1) almost all of this is open for discussion. If you disagree with any of this, have additions, or have better ways of doing things, let's discuss it on the list. 2) the initial code that I wrote doesn't necessarily follow all of these rules, since I was writing it as a "one-off" app that I didn't think would ever be used by anyone else. Bad assumption on my part ;-) Part of re-architecting the code will be to modify it to conform to the final coding standards we agree on. ---------------------------------------- Naming * Class Names - proper case example: " public class TestDbConnection " * Method Names - lower case first portion, then uppercase the beginnings of subsequent words example: " public String getDatabaseName " * Variable Names - same format as method names, except for member variables, covered next. * Member Variable Names - prefixed with "m_" example: " private String m_dbName " Braces & Indentation * Braces on the line following the declaration, and indented to the same spot * Indent each new nesting level 4 spaces * Convert tabs to spaces (I think most editors can be set to do this) Exception handling * Prefer to throw exceptions up to the top level, i.e., the presentation layer. Core code should basically be an api, and should not handle exceptions itself. There may be cases where the core code does need to handle exceptions, and this should be decided on a case-by-case basis. OO and Coding Philosophy * Define interfaces for our classes. Bind on these interfaces, rather than on the concrete classes * Challenge the existence of non-static member vars: are they only used in one method? If so, they should probably be loval variables declared in that method. * There should be accessor (get / set) methods for any member vars that require visibility outside the class itself. * Try to keep method size down: if a method starts getting large and convoluted, see if there are parts that stand alone, and can be extracted to other methods. * Prefer composition to inheritance: use the basic tests to determine which to use: "is a" vs. "has a", etc. * Javadoc your code, at the method and class level. Use appropriate comments throughout the code, without belaboring the obvious, i.e., you don't need to do something like this: //load the value of the first column in the ResultSet into a temp string String tmp = rs.getString(1); However, if there's some compelling reason that might not be obvious why you're performing the operation, comment that. |
From: William G. <ww...@ts...> - 2000-12-20 23:08:57
|
Hello, all -- Well, I'm finally getting a bit of time to devote to iJSQL ... I've published the starting coding guidelines to the site under documentation. I don't think it's visible yet, but should be there soon. Again, these standards are open to discussion. Also, I'm deep in the process of separating out the core and view code, making the core into an api that's useable by any choice of presentation layer. My goal is just to get us to a good starting point, where other views and other features are easy to add. There will undoubtedly be changes needed to what I do. I'll get this working and into cvs as soon as I can. Jukka, it also has your switchable connections, from the code you sent me a while back. If anyone else is currently working on any coding that will need to be included, let me know so I can integrate it. You'll get full credit in the changelog and my cvs checkin comment. If you'd rather have the checkin to cvs show your name, wait until I check in, then integrate your changes and check them in yourself. CVS needs cleaning up. I'll dig into the Sourceforge site docs to try to figure out how to get things fixed, and under the com.curiousmuse.ijsql package structure. Regards, Bill Graham |