jwenting 1,905 duckman Team Colleague

I fully agree that JBuilder is the best you can get, I'm a longtime user myself (since 1999 in fact with a 2 year stint into Eclipse).
But to really get that functionality you need the Developer (previously Professional) or Enterprise edition which isn't free (though IMO reasonably priced, especially the Developer edition).

Strangely many people don't seem to want to spend a cent on a piece of software they're going to be using for 5+ hours a day on average.
And that includes corporations which would earn back the investment in that software in hours from increased productivity while spending thousands upon thousands on new equipment for people that don't need it (don't get me started about marketing people getting brand new computers and screens while developers have to make do with 10 year old castoffs. I've been waiting to get a new stick of RAM for a year now while the CTO just got a 17" TFT to replace his 6 month old 15" one which still works perfectly well...).

jwenting 1,905 duckman Team Colleague

Check out the API docs for the interface and its implementing class which contain themselves links to other information.

jwenting 1,905 duckman Team Colleague

BlueJ is extremely limited for realworld use. VI is nice for sometime use, but again too limited to be really productive in a realworld environment (yes I use it too, and I like it, that's a professional opinion as a fulltime professional Java programmer).

I prefer JBuilder, though Eclipse is a decent alternative.

For LEARNING a language though (rather than using it professionally) no IDE should be used at all (not even a limited one like BlueJ) but rather a simple text editor with maybe syntax highlighting.
VI is excellent for this, as if Jedit.

jwenting 1,905 duckman Team Colleague

One way would be to build an array of characters when setting the text and building up a stringbuffer based on the content of that array (keeping the current index of the first character in memory) during each iteration.
You can then simply call toString() on the StringBuffer in order to set the text.

jwenting 1,905 duckman Team Colleague

That should be impossible. The applet sandbox prevents applets from doing ANYTHING on the client computer, and that includes opening browser windows.
This is for security reasons.

jwenting 1,905 duckman Team Colleague

If you use a single String you may want to check your performance and memory usage.
Could get substantial as Strings are immutable and thus a new String is being created for each iteration.

jwenting 1,905 duckman Team Colleague

That last was a jab at all the people who always say "Java is dead", "C++ is dead", "<name your language> is dead" :)

Cobol has been around for about 40 years now, and is still in largescale use today. I'd not be surprised at all if Cobol is still around when both Java and .NET are dead and forgotten.
Whereas both Java and .NET are used to create flashy internet and desktop applications (which typically have a short shelf life, they get replaced within a few years at most usually), Cobol runs the mainframes and supercomputers. Those applications are built to last, and run (with maintenance and upgrades for new and changed functionality) for decades almost uninterrupted.
They run so well in fact that there's no reason to shoulder the extreme cost of replacing them with something "more modern" (usually meaning Java or C++).

I was involved in one such massive Cobol project. The software had originally been created by another company some decade before we purchased it in 1992 (that was before I came on board). Last I heard (2003) it was still in active use and still being developed. That's 20 years for a single application, running on the same hardware all the time (ok, with upgrades to the hardware, adding harddisks and CPUs of course).

We were asked at one point by the customer to calculate the cost (in time and money) to replace the application with one created in C++.

jwenting 1,905 duckman Team Colleague

Just like that :)
I guess it's a Swing app?
Make a JPanel, put a Timer on it which on every tick rotates the text in a StringBuffer one character (or however much) and sets it to a JLabel on that JPanel.

Add the assembly to your application and turn on the timer.

jwenting 1,905 duckman Team Colleague

The problem with that is that many kids will continue to scream and rant until someone indeed does their entire assignment for them...

I've seen this in action many times here and (to a greater degree) elsewhere.

If someone shows a willingness to learn I'll be the last to deny them some help, but the problem with ever more kids is that they don't want to put in any effort themselves. Many would rather spend money to get a ready made solution than spend 5 minutes away from their playstations, it's getting that bad.

When we let kids with such attitudes get degrees and enter the marketplace as our potential colleagues, sooner or later we end up with them on a team and have to work overtime to cover for their incompetence and laziness until such a time as we can get it into the heads of management that these people are useless (and then how's the company going to get rid of them?).

By refusing them their easy grades, we help ourselves by removing them from the pool of available workers in the future.
Those of them who are intelligent enough to see the error in their ways will correct themselves and start to work, the rest we can only hope will fail their education and be reduced to unskilled labour where their attitude won't harm us.

If this sounds harsh, it's intended to. I've seen the damage lazy, unskilled people with degrees …

jwenting 1,905 duckman Team Colleague

Come back in 2 weeks and I may give an answer.

P.S. Java != JavaScript

jwenting 1,905 duckman Team Colleague

Check your serverlogs. Sounds like you may be causing some eternal loop or something like that.
Without the code for the JSP it's impossible to say anything more.

jwenting 1,905 duckman Team Colleague

hmm, nice connection at work. Guess there's not many people pumping data to clients at the moment :)

Your connection is: 3039 Kbps (about 3 Mbps)
You downloaded at: 371 kB/s
Your TRuSPEED: ^info^ 3252 Kbps :: 397 kB/s (7% overhead factored)

I've experienced faster though. Fastest was with a client where I downloaded 120+ megabytes in under 2 minutes.

jwenting 1,905 duckman Team Colleague

€55 a month for unlimited 2MB ADSL.
Demon Internet Netherlands.

For that I also get 20MB webspace (which I hardly ever use but it comes in handy for things like sigfiles and stuff), the option to run my own mailserver (which I do), a fixed IP address and (sub)domain name, webmail service for when I'm away from home, etc. etc. etc.

Not the cheapest option but I've only had about 3 hours outage since signing up with them in 1998, worth quite something to me.

jwenting 1,905 duckman Team Colleague

woman :) Narue is kinda particular about that ;)

jwenting 1,905 duckman Team Colleague

JSP can be used to create the user interface for a shopping cart system, sure.

It does not contain a complete ready made shopping cart system though, cannot and should not contain such a system.

jwenting 1,905 duckman Team Colleague

>I find the 500 character limit for the signature to be a bit less.

yes, I too think the limit should be a bit less than 500 characters. Maybe 100 should be enough...

jwenting 1,905 duckman Team Colleague

of course it doesn't, and why should it?

There's so many different implementations depending on the requirements for the particular system under development that it would be completely impractical for Sun to provide any implementation, even if it were something that was commonly needed by the majority of users (which it isn't).

There are probably ready made solutions available for purchase from third parties, if they can fit (or be made to fit) in your systems.

jwenting 1,905 duckman Team Colleague

Symptom:

Error "database unavailable" when trying to connect to a Firebird database even if fbserver is running fine (and Java applications connect, isql works great, remote clients can connect great, etc.).

Scenario:

You have just installed Firebird on a machine that previously had Interbase installed and are trying to run a Windows native application to connect to the database.

Solution:

Interbase installs GBD32.DLL into the Windows/System32 directory. When upgrading/moving to Firebird an option is given to create a legacy DLL for Interbase clients to connect to Firebird. This DLL must be manually copied over the existing GDB32.DLL from the bin directory of the Firebird installation.

Close the client application first (this can be Delphi for example if you're still writing it and get the error during development).

jwenting 1,905 duckman Team Colleague

they're located at http://java.sun.com where you can either view them online or download them to install on your computer.
You can also get the JDK there and loads of other goodies (like tutorials, online books, etc.).

jwenting 1,905 duckman Team Colleague

Better use String.split() instead of StringTokenizer. It will give you an array of Strings split on whatever you give it to use as a field separator.
As your data structure is pretty static you can then use that array and average all the data in it (while skipping the first of course) after converting the Strings to numbers.

See the API docs for details about String.split() :)

jwenting 1,905 duckman Team Colleague

Little if it's really dead.
There are companies that can retrieve (or try to) the data for you but those services cost thousands of dollars/Euros at least.

If the drive is still under warranty the best you can do is try to get a warranty replacement for it. Contact your drive manufacturer.
They might even be able to repair it if the damage is minor but often that's not feasible.

jwenting 1,905 duckman Team Colleague

You may be able to make something that runs on your machine and calls the profile update every few minutes but I don't think Dani would like that...

jwenting 1,905 duckman Team Colleague

> Microsoft bashing is cliche and annoying. Don't people have better things to think of and link to?

Apparently not. Remember the average mental age of web users is somewhere in the lower teens, even if the average physical age is in the mid to late 20s.

jwenting 1,905 duckman Team Colleague

You need to explicitly cast the object you retrieve from the List to the correct type unless you use a 1.5 level compiler in which case you can use generics to declare the List to only accept a specific type (and thus do the cast for you on retrieval).

You'd then declare the List as:

List<Item> myList = new LinkedList<Item>();
jwenting 1,905 duckman Team Colleague

hoard those invites, prevent gmail from stealing even more peoples' lifes by profiling them completely (which is what Google does, everything you write or receive is used to build up marketing profiles (for now...) of you and the other party (who doesn't even have to be a gmail subscriber and therefore doesn't even have to have given permission to be so profiled).

I for one have completely blocked gmail. Anything sent to me from the domain is bounced immediately.
I've also blocked any and all google cookies for the same reason. Google builds profiles based on those even when not using their websites (as they track the google ads received on any computer and account, again without the user ever agreeing to be so profiled).

jwenting 1,905 duckman Team Colleague

Everybody Hurts -- REM
Africa -- Toto
Brothers In Arms -- Dire Straits
The Great Beyond -- REM
Belleau Wood -- Garth Brooks
Old Shep -- Townes van Zandt

Just a few favourites in no particular order. I know most are a bit black

jwenting 1,905 duckman Team Colleague

don't get involved in pyramid schemes, they're illegal and pretty much all of them are scams.

jwenting 1,905 duckman Team Colleague

Not unless you use JNI to drive a DLL which calls whatever service your machine has running to measure the CPU temperature.
There may be 3rd party libraries doing at least some of the coding for you.

jwenting 1,905 duckman Team Colleague

Or try to get the better of them by creating a set of types I11I and II11 with each members l11l and ll11 (for example).
Of course even better in an editor using a sans-serif font like Arial ;)

jwenting 1,905 duckman Team Colleague

Netscape is crap.
Firefox is netscape on steroids (and with less bugs). So is IE in fact.

Netscape standards compliance is abysmal, performance is poor, the only reason noone writes exploits for the miriad holes in it is because noone uses it.

jwenting 1,905 duckman Team Colleague

indeed. I'd have changed it to m except that might be seen as slightly pickish :)
Of course using JBuilder it's extremely easy to replace all instances of a name with another, just click on the block edit button and change any one of them to change them all :cheesy:

jwenting 1,905 duckman Team Colleague

consistens class and method naming makes interaction between classes from others a lot easier.
And remember that in a professional environment coding standards are crucial and those include naming conventions. As the Sun conventions are logical and (of course) used by the standard API it's best to follow them as just about all the world does it.

I don't agree with all the Microsoft conventions for C(++) either, but when coding for Windows in C++ I do follow them for that very reason.
Same with Borland's standards for Delphi. Those are also open for debate, but following them makes for more transparency.

The greatest arrogance is thinking your ideas are better than those of the majority and following them even when it's in contradiction to commonly used best practice.

jwenting 1,905 duckman Team Colleague

Well, non-payment would cause the site to be taken down causing one or more of the symptoms I described :)

jwenting 1,905 duckman Team Colleague

Why would Java be easier to learn once you know php?
Java is nothing like php. php is now where JSP was around 1999, but JSP has moved on and is now nowhere near where it was back then.

If you want an easier entry into Java think about C++ and Delphi (yes, I know the syntax is different but the organisation is similar).

jwenting 1,905 duckman Team Colleague

Made it a bit smarter, couldn't help tinker and use some more features of the Tiger :)
The explicit cast to int Narue used was not needed, and the iteration can be performed using the new for-each loop in 4 lines less code than she used ;)

import java.util.*;

public class Scratch {
  public static void main(String[] args)
  {
    HashMap<Character, Integer> map = new HashMap<Character, Integer>();
    String theString = "This is a test that find the most common character";
    String unique = new String();

    for (int i = 0; i < theString.length(); i++) {
      if ( map.containsKey(theString.charAt(i))) {
        map.put (theString.charAt(i), map.get(theString.charAt(i)) + 1 );
      } else {
        map.put (theString.charAt(i), 1);
        unique += theString.charAt (i);
      }
    }
    for(Map.Entry item:map.entrySet())
        System.out.println(item.getKey() + ": " + item.getValue());
  }
}
jwenting 1,905 duckman Team Colleague

Told you the JLS is your friend :p

If you want more obscurity, here's the virtual machine specifications: http://java.sun.com/docs/books/vmspec/

jwenting 1,905 duckman Team Colleague

I've looked at it and liked what I saw. But as I'm working fulltime in Java and that's a large enough field to keep me busy I've little time to do much more.

jwenting 1,905 duckman Team Colleague

You can't, not with that compiler... It's an old realmode DOS compiler, and in those days (say the mid 1980s) memory segments were 64KB and could not get larger.
Switch to a more modern compiler (one that was written in the last decade or so).

jwenting 1,905 duckman Team Colleague

Java Language specification (second edition) section 12.1.4:

12.1.4 Invoke Test.main
Finally, after completion of the initialization for class Test (during which other consequential loading, linking, and initializing may have occurred), the method main of Test is invoked.
The method main must be declared public, static, and void. It must accept a single argument that is an array of strings.

http://java.sun.com/docs/books/jls/ a mandatory link for everyone using Java, it's the final word on everything.

jwenting 1,905 duckman Team Colleague

What's the problem?
You can implement this in several ways. Easiest is to have the environment know where all the fish are. Create a coordinate class (or just use the existing Point class) and give the fish a method to move them which takes the current coordinate and returns the new coordinate.
The environment can then check those new coordinates to determine whether the fishy bumped into something.

You could let the fish do that but that's a bit more complicated and may not be appropriate.

jwenting 1,905 duckman Team Colleague

Like my new one in fact, if it shows up :)

jwenting 1,905 duckman Team Colleague

Way too long. A good sig is no more than one line, 2 at most.

jwenting 1,905 duckman Team Colleague

First learn proper OO techniques and proper Java class naming. Then maybe I'll take a look.

jwenting 1,905 duckman Team Colleague

And be potentially impossible.
Which constructor should the JVM take after all?

jwenting 1,905 duckman Team Colleague

You should really dig into the API docs a bit. Depending on what you want to achieve you can use one of two classes at least to achieve what you want using only standard API functions.

jwenting 1,905 duckman Team Colleague

It all depends on your DVD player, your burner, your software, and the brand and type of recordables you use.
Some players won't accept any recordables or rewritables, others accept only certain types and recorded using specific protocols.

Check your manual for what will and will not work (and even then there's no guarantee).

That's the cost of having several competing "standards". Of course copying DVDs is illegal.

jwenting 1,905 duckman Team Colleague

And here I was thinking of having to get a fork lift or a construction crane ;)

jwenting 1,905 duckman Team Colleague

Use Tomcat 5 instead, Tomcat 3 is extremely outdated and doesn't understand current JSP programming systems which is what you should be using (JSTL mainly).

Installation is simple following the instructions from the download site (http://jakarta.apache.org ).

jwenting 1,905 duckman Team Colleague

so? That doesn't mean we should prevent him from ever learning anything by doing his homework for him...
In fact we're being kind to him by letting him know he should do his own work now rather than having him find out in a few years he's a useless programmer when he gets fired from his first job for being completely incapable.

jwenting 1,905 duckman Team Colleague

Look for expression parsers.

There's a nice example in the book "the art of Java" by Herbert Schildt and James Holmes. Nice book to read anyway with some rather interesting examples of what you can do with Java.