Need help calling java classes
- From: gremlin_dude@xxxxxxxxxxx (Gremlin Dude)
- Date: 27 Apr 2005 03:56:05 -0700
Hi. I am a beginner in java so i may sound like a total prat here,
but here goes:
I have been given my university coursework to do. I have to make a
program whereby a customer ordering boxes is asked what attributes of
a box he/she wants from list we have been given, then work out a price
for the box. Anyhow, we have six box types, so a class for each, an
Input class for reading input from the keyboard and a main class.
now, obviously the program starts in main, but i need to go to the
Input class as soon as the program starts, so i can put in some info
from the keyboard, but my tutor says that we have to separate the main
and input classes(whereas i can see it being easier to shove it all in
the main class), so i need to know this: How do you call one class
from another in java? I know how to call methods in one class:
methodname();, but i need to access the input class from the main
class. Is this possible or am i barking up the wrong tree? Help is
much appreciated.
Thanks
----------
Stuart
.
- Follow-Ups:
- Re: Need help calling java classes
- From: Hal Rosser
- Re: Need help calling java classes
- From: "."
- Re: Need help calling java classes
- From: kaeli
- Re: Need help calling java classes
- Prev by Date: Converting record stores (Palm) to ASCII
- Next by Date: Re: java and inheretance
- Previous by thread: Converting record stores (Palm) to ASCII
- Next by thread: Re: Need help calling java classes
- Index(es):
Relevant Pages
|
|