Don't you just love the first one?
for(i = Integer.valueOf(0); i.intValue() < lines.length;)
It doesn't even increment i within the loop!
Once again, concise and apposite advice from Scott...
Busted.
Sorry Scott,
Once again you are mostly right - protected methods can only be called by another method in the class definition thus indirectly allowing public access (again sounds like a very bad practice).
We also note that protected methods such as clone() can be promoted to public in an...
Thanks to all,
My reading of the API has Object.finalise() as recording a notification on exactly one thread - which could only support the GC in a multi-threaded environment.
Note that any object that inherits from Object (ie all objects except arrays) can call the protected method - but...
Hi JD Solutions,
Here's a tip - Javascript functions can have parameters, and I personally thimk "document.getElementById" is lazy programming.
function init(object JDNG) { //call JDNG.OnMyNumberChanged }
So why does the <object> declaration have to be in <body> ?
I'm not an expert but there...
Please forgive me everyone,
It is the finalize() method and not dispose() that I was curious about - ie when is it worth calling finalize() on a temporary.
Since I don't know how to close a discussion thread in this forum let's just say - woopse my mistake.
Jim.
Further to previous...
Rather than code I would prefer to send you the design specs.
Eventually the GUI will perform two sorts of topological analysis on this relational structure: (acyclic) transitive closure and various unions of equvalence classes - with all resilts returned as Collections...
Thanks for that Scott,
You have reminded me jus how important it is to get one's jargon right. Yes I did mean Collection and not a Container. I want the AWT/Swing components to display, and have direct access to every element "aggregated" by the current object (like in a graph).
What I do not...
Thank you Geeky.
Interestingly, I do not want to clone the collection; rather I do want the contained objects to be available for messages from the GUI (ie for real time interaction).
I have also wondered whether clear() on the returned copy (after its usage as a temporary) would shrink the...
My first advice is that in database design (ERD) the references are directed from the "Foreign key" towards the "Primary key".
In Java program design (O-O) the navigation is reversed, so that such one-to-many relations are accessed by calls on the elements of a collection from the object that...
I usually get these "cannot find symbol" messages when the environmental variable CLASSPATH has not been set.
Try doing this before you invoke Buildfile - looks like it might be: "/home/tomcat/apache-tomcat-7.0.21-src//output/build/temp".
Usually it is also best to also include "." in your...
The NullPointerException is an error thrown by calling a method without an agument: ParameterFieldController.do(Unknown Source)
If a method expects an object and is passed a null, invoking any methods on this "null argument" will generate an exception.
The source is obviously "unknown" because...
I have a class that encapsulates a Container, say Set, and I want the method getSet to return a *copy* of the data member (so as to preserving the privacy of access to the data member).
However, this method is accessed many times by the GUI interface, almost on every user driven event. What I...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.