Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

pollo

macrumors newbie
Original poster
Mar 31, 2007
1
0
hello everyone im new to the forum. Im currently taking computer science I and i am starting to learn all about java. At school all i have used is jCreator. i would just build files and run them; if i needed to make more than one i just put them all into one folder.(I did this all without projects) Now i have switched to a Mac things arent so easy because Xcode requires me to make projects, which i know nothing about or how to use them. I have tried to look at the guides and tutorials but they are too hardcore and are hard to understand for me because im just a beginner. I just want to make a few classes and be able to run them. For example, my assignment last week was to make a car class with 2 subclasses, sportscar and lemon. im just creating simple programs and it gets a bit frustrating with all this project thing. Can someone out there please help me? i would be eternally grateful:)
 

Eraserhead

macrumors G4
Nov 3, 2005
10,434
12,250
UK
Xcode isn't great for Java, professionally you use Eclipse or something, but for a beginner you need a simple text editor, which I'm sure you can get some suggestions for, though for now you can use Xcode (without projects). This is just to save the files as .java files, then use javac on the command line to compile them. Your lecturer should be able to help you with javac.
 

lazydog

macrumors 6502a
Sep 3, 2005
709
6
Cramlington, UK
Hi

I find Xcode more than adequate for developing Java programs. A little patience and you will get used to its interface. Xcode has several 'layouts'. I find the 'all in one' layout the easiest to work with. You can change the layout mode under 'Preferences'. In Xcode select 'new project'. From the list of available projects select 'Java Tool'. The standard project settings should be fine. Assuming you are in 'all in one' layout, select the 'Build' view. This is the hammer icon in the top left of the window. You can add files by right clicking in the Groups & Files tree. Just hit build and run. Pretty simple really? You might find it easier if you customise the menu bar. The only thing you need to do in a new project is reveal the editor. Easiest way is to select 'Zoom editor in' under the 'View' menu item.

b e n
 

pMay

macrumors member
Mar 24, 2007
30
0
I defenitly would use Eclipse cause it has alot of plugins that are very helpful. Also many other ppl are using it.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.