Need help calling java classes



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
.



Relevant Pages

  • Re: Need help calling java classes
    ... I am a beginner in java so i may sound like a total prat here, ... > Input class for reading input from the keyboard and a main class. ... they want you to develop this skill. ... darrell dot grainger at utoronto dot ca ...
    (comp.lang.java.help)
  • Re: Need help calling java classes
    ... > Input class for reading input from the keyboard and a main class. ... Is this possible or am i barking up the wrong tree? ... public String getInput() ...
    (comp.lang.java.help)