I am new to programming and have a project due and am at a total loss. I've been sitting here reading the book for two hours and can not figure my problem out.

Here is my project:
You're helping Danny Ocean with his plot to rob a casino or two in the Las Vegas area. Unlike in the movie, Danny has not already decided which casinos to rob: his personal grudge against their owner was worked out in therapy sessions. Nonetheless, Danny has a standard of living to maintain, and hence will be doing some sophisticated research about the casinos from which he will ultimately choose.

He has brought you into his ring of crime by contracting you to write some software for him which will enable him to track the casinos and some key properties of them. Here's the piece of code you must write for now:

Write a class called Casino which will hold several important pieces of information regarding the casino. It will hold the name of the casino, the name of the owner, the address of the casino, the level of difficulty of getting into the vault, and the average amount of cash usually kept in the vault.

The level of difficulty should be stored as an enumerated type with the following values as its fields:

impossible, veryDifficult, difficult, easy, veryEasy

You will need a constructor, methods to get and set each variable, and a method called checkOwner which will accept a string as a parameter and return a boolean value depending on whether the owner's last name begins with the string passed in as a parameter.

You will write a driver to test your class, but you will only turn in the class to me.

You'll have to store the first name and last name separately, but that should not be apparent to the client upon calling getName(). You will also need to make your checkOwner() method non-case sensitive, so you should uppercase or lowercase all strings to be compared. Read about toUpperCase() and toLowerCase() in the String class API.

You do not need to write a setName() method. That will come later.

Here's a complete list of methods you'll need along with the types and orders of their parameters. On the constructor, you do not need to name your parameters identically to mine, but you do need to put them in the same order. NAME YOUR METHODS EXACTLY AS I HAVE OUTLINED BELOW.

Casino(String casinoName, String ownerFirstName, String ownerLastname, String address, DifficultyLevel d, int averageCash)

getCasinoName()
setCasinoName(String)
getOwnerName()
getAddress()
setAddress(String)
getAveragecash()
setAverageCash(int)
checkOwner(String)
toString()

I basically do not have anything done. I am mainly trying to figure out how to start and how to do these get and sets.

ANY help would be greatly appreciated!

you need to create a class with properties that you pass to your constructor.
and you simply write get, set methods for them.... an example :

public class book {
//properties
String name;
String Author;
int pages;
//here is the constructor;
public book(String name, String Author, int pages) {
this.name= name;
this.Author= Author;
this.pages= pages;
}
//getters, setters...
public String getName() {
return name;
}
public String getAuthor() {
return Author;
}
public int getPages() {
return pages;
}

public void setName(String newName) {
 this.name =newName;
}
public void setAuthor(String newAuthor) {
 this.Author =newAuthor;
}
public void setPages(int newPages) {
 this.pages =newPages;
}

}

only difference in your code will be in checkOwner(String) which you need to make a comparation and getOwnerName() , which you need to join to Strings...

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.