Page 1 of 2

Where to go for Java Help??

Posted: Mon Sep 25, 2006 7:03 pm
by Pyrite
IMHO, phpDN is the abs() BEST!!! resource, other than the php manual for getting help with PHP. I am amazed at how many people post here and how often too, and how knowledable and friendly the members are as well!

So after doing PHP for 6 years, I am back in college, and lo and behold, I am taking a Java course (pftttt). My impressions of Java are pretty weak so far, but like PHP, it is fun to learn and play with. So my question is, is there like a JavaDN forums out there? What forums would be the equivalent to these for Java peeps?

So far, I find the amount of documentation, forums and help for Java online a bit lacking, especially compared to PHP. But I will give Java the benefit of the doubt and just ask.

Code: Select all

phpDN.equals("http://???");
:D :D

Posted: Mon Sep 25, 2006 10:12 pm
by neophyte
I spent sometime digging around for Java sites a few weeks ago. The best thing I could find were toot's mostly on the Sun site. I never did find an online Java community. I figure it's probably because Java is a base language for most Computer Science programs. Like who wants to do Java for fun when it's forced on you all day at work/college... Okay now I'm just guessing. I'm interested in this one if anyone else has tips.

Posted: Mon Sep 25, 2006 10:29 pm
by wtf

Posted: Tue Sep 26, 2006 1:57 am
by christian_phpbeginner
Here is a good resource to start learning Java:
http://java.sun.com/javase/reference/tutorials.jsp

API and Docs:
http://java.sun.com/javase/reference/api.jsp

Free Online Classroom, which is also good, and you can find friends and colleagues there too:
http://www.javapassion.com/javaintro1/

And if you want books:
1. Java 2: A Beginner's Guide. By Herbert Schildt. --> Beginner
2. J2SE 5 Edition: The Complete Referene. By Herbert Schildt. --> Intermediate to Advance
3. The Art Of Java. By Herbert Schildt. --> Advance
4. Instant Java Server Pages. By Tremblett. --> More to implementation
5. J2EE and Beyond (forgot the author).--> More to implementation and discuss more details on J2EE.

Chris

Posted: Tue Sep 26, 2006 6:10 am
by timvw

Posted: Mon Oct 02, 2006 11:35 pm
by Pyrite
Thanks for all the replies guys! I made a 107 on my first assignment, which is a Slot Machine game (and yes, I did find a way to use PHP in this assignment, check out my program to see how :wink: )

http://www.pysquared.com/viewpost.php?pid=92

Posted: Tue Oct 03, 2006 8:30 am
by SpecialK
That was your FIRST assignment?! I think my first Java was a Hello World :P

Quite enjoyable laughing at the sounds. That alone makes me want to keep playing :)

Posted: Tue Oct 03, 2006 8:47 am
by neophyte
"Whatever your name is, get ready for the big suprise"

Nice first project!

Posted: Tue Oct 03, 2006 9:58 am
by jayshields
haha, that's ace. I'm top score :D

I just started programming Java today. Just done my first task. Too easy :(

Posted: Tue Oct 03, 2006 1:17 pm
by timvw
Ah well, if you want a bit of a challenge, see if you can figure out web.xml mappings, hibernate mappings and setup a simple site that uses hibernate to fetch some data from the database ;) (happy learning ;))

Posted: Tue Oct 03, 2006 1:17 pm
by Pyrite
Well, we had several labs in class, but that was our first take home "real" assignment, after 4 weeks of class. However, my first Java program I wrote (which was before school started) was an Ascii to Binary program.

Thanks for the compliments guys. I really spent a lot of time on that one to make it real nice.

Posted: Tue Oct 03, 2006 1:20 pm
by Pyrite
timvw wrote:Ah well, if you want a bit of a challenge, see if you can figure out web.xml mappings, hibernate mappings and setup a simple site that uses hibernate to fetch some data from the database ;) (happy learning ;))
Actually I already started one project that interfaces with MySQL from Java. So far I just have it reading one query of a bunch of names into a JList inside a JScrollPane. Anyone have any experience using SQLite with Java? I haven't been able to get any of the wrappers to work yet.

Posted: Tue Oct 03, 2006 1:22 pm
by timvw
Pyrite wrote:Well, we had several labs in class, but that was our first take home "real" assignment, after 4 weeks of class. However, my first Java program I wrote (which was before school started) was an Ascii to Binary program.

Thanks for the compliments guys. I really spent a lot of time on that one to make it real nice.
It's pretty nice ;)

PS: If you want some bonus points: Where's the webstart? And why aren't the resources not bundled with the jar? ;) (hint: yourinstance.getClass().getResourceAsStream (...))

Posted: Tue Oct 03, 2006 1:25 pm
by Pyrite
timv, apparently when using the sun.audio classes to play sounds, bundling the sound files inside the jar isn't supported. Sun I think officially knows this, but since the sun.audio classes are unofficial, they don't provide any support for them, nor care about fixing bugs. That's just what I read though, when i tried to bundle them it would throw an exception with them not found. I haven't tried though with javax.sound.sampled yet.

Posted: Tue Oct 03, 2006 1:28 pm
by Pyrite
timv, And what do you mean by webstart?

Here's the helper method I made for the sounds.

Code: Select all

/**
     * Plays a voice sound from Arnold, the Govenator.
     * The sound files must be located in the same directory
     * as the executable JAR file.
     *
     * @param sound The 2nd half of the sound file name,
     * before the .wav and after the snd_
     */
    public static void playSound(String sound) {
        String filePath = System.getProperty("java.class.path").substring(0, System.getProperty("java.class.path").lastIndexOf('\\') + 1);
        try
        {
            filePath                = filePath + "snd_"+sound+".wav";
            InputStream inputStream = new FileInputStream(filePath);
            AudioStream audioStream = new AudioStream(inputStream);
            AudioPlayer.player.start(audioStream);
        }
        catch (FileNotFoundException e)
        {
            System.out.println("Didn't find audio file.");
        }
        catch (IOException e)
        {
            System.out.println("Input Error with sound file.");
        }       
    }