Needs help.....Please about using different classes

I don't know how to use differenet classes.
Please tell me how to write class to suit Start. This stuff me up. Please .... help me
<<My program>>
//Start
public class Start
{  private Artist[] Artists;
private Record[] records;
private Person[] Manager;
private TextMenu makeMenu = new TextMenu();
public static void main(String[] args)
     Start studio = new Start();
studio.menu();
public Start()
{  //Person.Manager(ManagerName,HouseNumber,StreetNumber,PhoneNumber)
     Manager = new Person[1];
     Manager[0] = new Person("Yangfan",88,"Young ST",11118888);
     //Artist(GroupID,ArtistName,HouseNumber,StreetNumber,PhoneNumber)
     Artists = new Artist[5];
Artists[0] = new Artist(1,"Backstreet Boys",58,"Music ST",99998888);
Artists[1] = new Artist(2,"Santana",68,"Music ST",99998899);
Artists[2] = new Artist(3,"Macy Gray",78,"Music ST",55558888);
Artists[3] = new Artist(4,"Ricky Martin",88,"Music AVE",77778888);
Artists[4] = new Artist(5,"Did Rock",55,"Music Road",66667777);
//Record(RecordingID,RecordName,Artist,StartTime,FinishTime,RecordingDate,GuestArtist1,GuestArtist2)
records = new Record[6];
records[0] = new Record(1,"I want it that way",Artists[0],11,12,"05/08/2001",Artists[1],Artists[3]);
records[1] = new Record(2,"Smooth",Artists[1],11,12,"05/08/2001",Artists[1],"");
records[2] = new Record(3,"Do something",Artists[2],11,"05/08/2001",Artists[3],"");
records[3] = new Record(4,"Livin La Vida Loca",Artists[3],11,12,"05/08/2001",Artists[1],Artists[3]);
records[4] = new Record(5,"Bawitdaba",Artists[4],11,13,"05/08/2001",Artists[1],"");
records[5] = new Record(6,"The one",Artists[0],11,14,"05/08/2001",Artists[1],"");
public void menu()
{  String[] choices = {">>>List Manager Details",">>>List All Artist Names",">>>List An Artist Telephone-Number",">>>Show Details For One Recording",">>>Add A New Recording",">>>List The Recording Costs For All Artists",">>>List Artist's Reocording",">>>Exit Program"};
while (true)
{  switch (makeMenu.getChoice(choices))
{  case 1: showAllArtists();
break;
case 2: showAllRecords();
break;
case 3: System.exit(0);
break;
case 4: System.exit(0);
break;
case 5: System.exit(0);
break;
case 6: System.exit(0);
break;
case 7: System.exit(0);
break;
case 8: System.exit(0);
break;
default:
public void showAllArtists()
{  int numArtists = Artists.length;
for(int i = 0; i < numArtists; i++)
{  Artists[i].displayArtistDetails();
public void showAllRecords()
{  for (int i = 0; i < records.length; i++)
{  System.out.println();
records.printRecordDetails();
<<Assignment>>
Due - midnight, Wednesday August 22nd
This assignment will test your knowledge of Java programming using classes, encapsulation and javadoc.
The base requirements
Write a complete Java class to manage a Digital Recording Studio. The studio wants to keep a list of all Artists that use the studio and also wishes to keep track of all Recordings that have been made. An important function of the program is to calculate the time spent making a recording and charge the Artist for the time used.
You must create at least the following classes, Start, Studio, Person, Artist, Recording, Address. You may create other classes if needed as well
Start will contain main(), create one instance of a Studio and execute a Menu of commands to test your code. Studio should contain a studio name, an array of Artist and an array of Recording plus the studio manager (a Person). Each Artist should contain the name of the group and an Address. Each Person will have a name and a home address. Each recording will have a Title (usually song title), an Artist (only one), and a list of guestArtist (they are Artist�s but will not receive royalties) the number of the CD the recording is stored on (numbers are numerical and recordings are saved on CD-R), plus the recording start and finish times for the recording session (suggest you use Java Date class � refer to the API). An Address will contain, house number (integers only), a street name and a telephone number. There is no need to store city and country.
To enter a set of data for testing your program � main() should call a method in the Start class that will fill in a set of values by creating objects and filling in values by calling methods in each class. This is the ONLY method allowed to be longer than 1 page long � normally we would read the data from a file but there are no O-O principles that can be learnt with simply filling in data values. It is suggested to create say at least 4 Artist�s and 6 Recordings (at least one with 1 guest Artist and one with 2 guestArtist�s)
A menu for testing your program should be provided (it is suggested to put the Menu into a separate class as you need at least 3 menus). While other commands are possible, only the following ones will receive marks.
Menu commands needed are
List the Managers name, address and telephone number
List all Artist Names
List an Artist telephone number (a sub menu showing valid Artist�s is required)
Show all details for one Recording ( sub menu of valid Recordings will be needed and remember there can be more than one guestArtist)
Add a new Recording, user will need to be prompted for all details.
List the recording costs for all Artists � show each Artist on a separate line with their name and total amount, charge for using the studio is $1000 per hour or part thereof, example for a 1 hour and 10 minute recording the Artist will be billed for 2 hours.
List all the Recording�s one Artist has worked on (sub menu of Artists needed), the list should show whether they were the Artist or a guestArtist
Exit program
Use fixed sizes for arrays, suggest 20 is suitable for all arrays. Java can handle dynamic data structures (where the number of elements can grow or shrink), but that is beyond a first assignment.
Do NOT make ANY methods static - this defeats the Object Oriented approach and will result in ZERO marks for the entire assignment.
Data MUST be encapsulated, this means that all the data relating to an object are to be stored INSIDE an object. None of the data detail is to be globally available within your program - hence do not store Artist names in either Studio or Recordings � just store a reference instead. Do NOT create ID numbers for Artists, you should use References instead � for many students this will be the hardest part as you have to use Objects, not program in a C style to solve the problem. Note that if there are any non-private data in classes then zero will given for marks for encapsulation.
Good programming style is expected (see web page or lecture notes). In particular, you must use javadoc to generate a set of html pages for your classes. Make sure you use the special javadoc style comments in your source code. Marks will be granted for both using javadoc and also for including sensible javadoc comments on each class and each public method.
What to Hand In
Read the turnin page, basically the .java files, a readme.txt to tell the marker which file the program starts from plus the javadoc (html) files. Do NOT send .class files (if you do send these we will delete them and recompile your program), do NOT compress with gtar, tar, zip or use any other tool on your files. Turnin automatically compresses all your files into a single archive for us to mark.
The simplest way to turnin all your files is to place all files in one directory then just use the *.* wildcard to turn in all files within that one directory.
You must turnin all files that are not part of Java 1.3. In particular, you are allowed (actually encouraged) to use EasyIn or SavitchIn but should include the one you use in the files you submit. It is STRONGLY suggested that you copy all the files into another directory, test it works there by compiling and executing then turnin files from that directory. A common problem is students adding comments at the last minute then not testing if it still compiles. The assignment will be marked as submitted � no asking later for leniency because you added comments at the last minute and failed to check if it still worked.
If the tutors are unable to compile your submission, they will mark the source code but you will lose all the execution marks. Sorry, but it is your responsibility to test then hand in all files.
Comments
For CS807 students, this program should be fairly easy if it was to be programmed in C (you would use several struct). The real art here is to change over to programming objects. Data is contained in an object and is not global. This idea is essential to using Java effectively and is termed encapsulation. Instead of using function(data), you use objectName.method( ). Effectively you switch the data and functions around, the data has a method (function) attached to it, not the other way around as in C (where you have a function and send data to it).
While there will be some marks for execution, the majority of the marks will be given for how well you write your code (including comments and documentation) and for how well you used O-O principles. Programs written in a C style with most of the code in one class or using static will receive ZERO marks regardless of how well they work.
You are responsible for checking your turnin by reading the messages turnin responds with. Failure to read these messages will not be an acceptable excuse for submitting an incorrect assignment. About 2% of assignments sent to turnin are unreadable (usually empty) and obtain 0.
Late submissions
Late submissions will only be accepted with valid reasons for being late. All requests for assignment extensions must be made via email to the lecturer. Replies for acceptance or refusal will made by email. Instant replies are unrealistic (there is usually a flood of queries into my mail box around assignment due dates) and the best advice is to ask at least 4 days in advance so that you will have a reasonable chance of getting a timely reply and allow yourself enough time to submit something on time if the extension is not granted.
ALL late submissions will be marked LAST and will NOT be sent to tutors for marking until all other assignments have been marked. As an example, if you submit late and your assignment is not yet marked by the time assignment 2 is due then it will be pushed to the end of the marking pile as the assignments that were submitted on time for assignment 2 will take priority.
If you make a second submission after the submission date, only the first submission will be marked. We will not mark assignments twice! You can update your submission BEFORE the submission date if you need to - this will just overwrite the first submission. The latest time for a late submission is 5pm on the Wednesday after the due date. This is because, either a solution will be handed out at that lecture or details of the assignment will be discussed at the lecture. I cannot accept any assignment submissions after that time for any reason at all including medical or other valid reasons. For those who are given permission to be later than the maximum submission time � a different assignment will be handed out. Remember, if you decide to submit late you are VERY UNLIKELY to receive feedback on your assignments during semester.
Assignments will be removed from turnin and archived elsewhere then forwarded to tutors for marking on the morning after the assignment is due. A different tutor will mark each of your assignments � do not expect the tutor you see at the tutorials to be your marker.
Marks will be returned via email to your computer science yallara account � ideally within 2 weeks. I will send marks out when I receive them so do not send email asking where your marks are just because a friend has theirs. If you want your email forwarded to an external account, then place a valid .forward file into your yallara account. The Help Desk on level 10 can assist you in setting this up if you do not know how to do it.

I have seen other people who have blatantly asked for
other people to do their homework for them, but you
are the first person I've seen to actually cut and
paste the entire assignment as it was handed to you.
Amazing.
Well, unlike some of the people you're talking about, it seems like zyangfan did at least take a stab at it himself, and does have a question that is somewhat more sepcific that "please do this homework for me."
Zyangfan,
marendoj is right, though. Posting the entire assignment is kind of tacky. If you want to post some of it to show us what you're trying to do, please trim it down to the essential points. We don't need to see all the instructor's policies and such.
Anyway, let me see if I understand what you're asking. You said that you know how to write the code, but only by putting it all in one class, is that right? What part about using separate classes do you not understand? Do you not know how to make code in one class aware that the other class exists? Do you not know how code in class A can call a method in class B?
Please be a bit more specifice about what you don't understand. And at least try using multiple classes, then when you can't figure out why something doesn't work, explain what you did, and what you think should have happened, and what did happen instead.
To get you started on the basics (and this should have been covered in your course), you write the code for two classes just like for one class. That is, for class A, you create a file A.java and compile it to A.class. For class B, you create a file B.java and compile it to B.class. Given how rudimentary you question is, we'll skip packages for now. Just put all your class files in the same directory, and don't declare packages in the .java files.
To call a method in class B from code that's in class A, you'll need an object of class B. You instantiate a B, and then call its methods.
public class B {
  int count;
  public B() { // constructor
  public void increment() {
    count++;
public class A {
  public static void main(String args[]) {
    B b = new B();
    b.increment();
}Is this what you were asking?

Similar Messages

  • Need help please about GREP in InDesign

    hi all
    i'm using indesign cs4 ME version/
    when i'm trying to add a GREP expression in a paragraph style. when i want to select an GREP expression from the icon right to the text field - another windows apear but all the GREP expression are in grey and not active. (see image attached)
    someone know why?
    if I type an GREP expression without using this right-side menu - it's all OK and works - BUT the problem that Im not know all the expression...
    in the find / change menu (from the edit menu) - when we can use the GREP to find and replace (without using styles) - there is no problem and the icon right to the text field is active.
    please help
    thanks
    shahar
    [email protected]

    The other Peter didn't get the instructions quite correct. For Windows it's Ctrl + Alt + Shift, for Mac it's Cmd + Ctrl + Opt + Shift, and you have to press them all together immediately after launching ID. If you are fast enough you'll see a confirmation dialog.
    For instructions on manually backing up and deelting the prefs if that isn't working, or you just don't want to lose customizations unnecessarily, see: Replace Your Preferences

  • Need Help Please about flash based template

    Dear Sir
    I have a flash template with .fla file . I want to know that how i can attach the links of files name iframe_0.html / iframe_1.html / iframe_2.html / iframe_3.html / iframe_4.html to their relevant button at home page .The home page menu is also flash based.
    For details see attachment
    Link : http://img33.imageshack.us/img33/9999/99617025.jpg
    Please guide me how i can attach the frames by using Adobe Dream Weaver under the desired button
    For Example
    If i clicked on button name : company     then  iframe_1.html should be appear with data etc..
    Regards 

    Flash cannot be viewed by the most popular web devices (iPhone, iPad, iTouch, modern Androids, etc...), and that list is getting bigger.  Why would you even think of using Flash for your web site?
    Nancy O.

  • I had a problem with my itunes so i had went on itunes website and reinstall itunes for windows and after it complete it said that the feature yoy are trying to use is on a network resource that is unavailable i need help please!!!!!!!!!

    had a problem with my itunes so i had went on itunes website and reinstall itunes for windows and after it complete it said that the feature yoy are trying to use is on a network resource that is unavailable i need help please!!!!!!!!!

    first, head into your Add/Remove programs and uninstall your QuickTime. if it goes, good. if it doesn't, we'll just attend to it when we attend to itunes.
    next, download and install the revo uninstaller http://http://www.revouninstaller.com/revo_uninstaller_free_download.html. use it to clear any existing itunes and/or QuickTime installation configuration information from the PC.
           next download itunes. it worked for me hope this is helpful!!
        oonce you get into the revo uninstallergo thru to delete itunes hit uninstall on the itunes icon then you will go thru to it will tell u the same nmessage about the feature and network hit cancell then go thru and hit scan (make sure bthe advance scan button is pushed) this will take awhile but go thru the list and hit everything associated with itunes. hit delete then install itunes again. it worked for me hope it works for you!

  • HOW TO?: Need help setting up 3 different iCloud accounts for my kids (so each has own iMessanger)using same Apple ID (mine) ....they don't have their own separate email addresses to work from...how do I do this?

    Need help setting up 3 different iCloud accounts for my kids (so each has own iMessanger)using same Apple ID (mine) ....they don't have their own separate email addresses to work from...how do I do this?

    Any devices connected to the same icloud account can sync all the data on that account.  For this reason an icloud account is really for a single user.
    On a mac, if each user has their own account, then the itunes for that mac account should be set up to connect to that user's icloud account (System preferences>icloud).

  • HT4314 Hi i need help please i been playing clash of clans over 13 months. And today o realise what someone using my game Centra. Someone playing on my game Clash of Clans. I been change my Apple ID password, email, but doesn't work. Then I playing game I

    Hi i need help please i been playing clash of clans over 13 months. And today o realise what someone using my game Centra. Someone playing on my game Clash of Clans. I been change my Apple ID password, email, but doesn't work. Then I playing game I can see what someone else trying connecting to my game And I don't know what to do.So if you can help me please? I don't wanna lose my game.

    Contact iTunes
    Contact iTunes

  • Hi i need help please i been playing clash of clans over 13 months. And today o realise what someone using my game Centra. Someone playing on my game Clash of Clans. I been change my Apple ID password, email, but doesn't work. Then I playing game I can se

    Hi i need help please i been playing clash of clans over 13 months. And today o realise what someone using my game Centra. Someone playing on my game Clash of Clans. I been change my Apple ID password, email, but doesn't work. When I playing game I can see what someone else trying connecting to my game And I don't know what to do.So if you can help me please? I don't wanna lose my game. 

    Hello Vaidas Vaidas,
    It sounds like you are noticing someone else is accessing your Clash of Clans data by playing the game and you have tried to reset your Apple ID password. If you are following the steps outlined in this article:
    Apple ID: Changing your password
    http://support.apple.com/kb/ht5624
    What is preventing you from changing your password? Any error messages or prompts?
    Thank you for using Apple Support Communities.
    All the best,
    Sterling

  • After many months of non-use, when I opened Photoshop CS4 Extended, I got an error message 148.3.  "Licensing for this product has stopped working."  I need help, please.

    After many months of non-use, when I tried to open Photoshop CS4 Extended, I got an error message 148.3.  "Licensing for this product has stopped working."  I need help, please.

    Error "Licensing has stopped working" | Windows
    Error "Licensing has stopped working" | Mac OS
    Mylenium

  • I need help please , i try to use itunes but my iPhone don't appear on itunes, i try everyting ,dowwload itunes again restart computer and iPhone,restart running device support,etc.

    i need help please , i try to use itunes but my iPhone don't appear on itunes, i try everyting ,dowwload itunes again restart computer and iPhone,restart running device support,etc.

    Windows doesn't detect iPhone: http://support.apple.com/kb/ts1538
    Mac: http://support.apple.com/kb/ts1591

  • Hii i need help i cannot use my apple id for download on app store because they say i need to verify my account but i don't know how so please somebody can help me? i try to resset my password but that don't help

    hii i need help i cannot use my apple id for download on app store because they say i need to verify my account but i don't know how so please somebody can help me? i try to resset my password but that don't help

    is it asking for ur security questions?

  • HI. When I plug in my charger and use my macbook, I feel some kind of roughness on the body. It feels like some current flowing around it. Need help please.

    HI. When I plug in my charger and use my macbook, I feel some kind of roughness on the body. It feels like some current flowing around it. Need help please.

    My 2006 MacBook Pro and my 2011 MacBook Air both do it.  It happens because the earth ground stops at the power brick and is not carried through to the case of the machine.  It is not dangerous or the machine would not have been UL approved.
    Since I operate on battery 99.9999% of the time it doesn't bother me at all.

  • Help please am useing an Iphone 3gs after i restore the iOS device restart my phone can not Activate it.. what do i do please i need your help.?

    Help please am useing an Iphone 3gs after i restore the iOS device restart my phone can not Activate it.. what do i do please i need your help.?

    Usually indicitive of a phone that's been jailbroken or hacked to unlock it, something of which you will net get support for here.

  • HT1937 I have an iphone bought in the UK but I'm in Europe and can not use it I need help please help me thanks

    I have an iphone bought in the UK but I'm in Europe and can not use it I need help please help me thanks

    wiliiam rrichard wrote:
    Because My iphone is Locked on the United Kingdom
    No it is not.  iPhones, like all cell phones are not locked to countries.  They are locked to carriers.
    Only the carrier to whom the device is locked can unlock it.  Contact the carrier.

  • HT204380 I can't access my FaceTime and messages through my iPod touch, I need help please!!!

    I can't access my FaceTime and messages through my iPod touch, I need help please!!!

    Using FaceTime http://support.apple.com/kb/ht4319
    Troubleshooting FaceTime http://support.apple.com/kb/TS3367
    The Complete Guide to FaceTime + iMessage: Setup, Use, and Troubleshooting
    http://tinyurl.com/a7odey8
    Troubleshooting FaceTime and iMessage activation
    http://support.apple.com/kb/TS4268
    Using FaceTime and iMessage behind a firewall
    http://support.apple.com/kb/HT4245
    iOS: About Messages
    http://support.apple.com/kb/HT3529
    Set up iMessage
    http://www.apple.com/ca/ios/messages/
    Troubleshooting Messages
    http://support.apple.com/kb/TS2755
    Setting Up Multiple iOS Devices for iMessage and Facetime
    http://macmost.com/setting-up-multiple-ios-devices-for-messages-and-facetime.htm l
    FaceTime and iMessage not accepting Apple ID password
    http://www.ilounge.com/index.php/articles/comments/facetime-and-imessage-not-acc epting-apple-id-password/
    Unable to use FaceTime and iMessage with my apple ID
    https://discussions.apple.com/thread/4649373?tstart=90
    For non-Apple devices, check out the TextFree app https://itunes.apple.com/us/app/text-free-textfree-sms-real/id399355755?mt=8
    You posted in the iPad forum instead of the iPod forum. To get answers to your question, next time post in the proper forum. See https://discussions.apple.com/index.jspa  I'll request that Apple relocate your post.
     Cheers, Tom

  • HT1212 My Ipad is disabled by wrong password and I have tried to reset and restore a few times with no success. Now I-tunes won't even recognize the I-pad in recovery mode. I need help please.

    My Ipad is disabled by wrong password and I have tried to reset and restore a few times with no success. Now I-tunes won't even recognize the I-pad in recovery mode. I need help please.

    If the iPad was running iOS 7,  iCloud: Find My iPhone Activation Lock in iOS 7
    http://support.apple.com/kb/HT5818
    How can I unlock my iPad if I forgot the passcode?
    http://www.everymac.com/systems/apple/ipad/ipad-troubleshooting-repair-faq/ipad- how-to-unlock-open-forgot-code-passcode-password-login.html
    iOS: Device disabled after entering wrong passcode
    http://support.apple.com/kb/ht1212
    How can I unlock my iPad if I forgot the passcode?
    http://tinyurl.com/7ndy8tb
    How to Reset a Forgotten Password for an iOS Device
    http://www.wikihow.com/Reset-a-Forgotten-Password-for-an-iOS-Device
    Using iPhone/iPad Recovery Mode
    http://ipod.about.com/od/iphonetroubleshooting/a/Iphone-Recovery-Mode.htm
    Saw this solution on another post about an iPad in a school environment. Might work on your iPad so you won't lose everything.
    ~~~~~~~~~~~~~
    ‘iPad is disabled’ fix without resetting using iTunes
    Today I met my match with an iPad that had a passcode entered too many times, resulting in it displaying the message ‘iPad is disabled – Connect to iTunes’. This was a student iPad and since they use Notability for most of their work there was a chance that her files were not all backed up to the cloud. I really wanted to just re-activate the iPad instead of totally resetting it back to our default image.
    I reached out to my PLN on Twitter and had some help from a few people through retweets and a couple of clarification tweets. I love that so many are willing to help out so quickly. Through this I also learned that I look like Lt. Riker from Star Trek (thanks @FillineMachine).
    Through some trial and error (and a little sheer luck), I was able to reactivate the iPad without loosing any data. Note, this will only work on the computer it last synced with. Here’s how:
    1. Configurator is useless in reactivating a locked iPad. You will only be able to completely reformat the iPad using Configurator. If that’s ok with you, go for it – otherwise don’t waste your time trying to figure it out.
    2. Open iTunes with the iPad disconnected.
    3. Connect the iPad to the computer and wait for it to show up in the devices section in iTunes.
    4. Click on the iPad name when it appears and you will be given the option to restore a backup or setup as a new iPad (since it is locked).
    5. Click ‘Setup as new iPad’ and then click restore.
    6. The iPad will start backing up before it does the full restore and sync. CANCEL THE BACKUP IMMEDIATELY. You do this by clicking the small x in the status window in iTunes.
    7. When the backup cancels, it immediately starts syncing – cancel this as well using the same small x in the iTunes status window.
    8. The first stage in the restore process unlocks the iPad, you are basically just cancelling out the restore process as soon as it reactivates the iPad.
    If done correctly, you will experience no data loss and the result will be a reactivated iPad. I have now tried this with about 5 iPads that were locked identically by students and each time it worked like a charm.
    ~~~~~~~~~~~~~
    Try it and good luck. You have nothing more to lose if it doesn't work for you.
     Cheers, Tom

Maybe you are looking for