FileDocCategorySizeDatePackage
Person.javaAPI DocExample652Sun Feb 29 12:51:00 GMT 2004None

Person

public class Person extends Object
A sample class used in some of the notes accompanying this code set. N.B. This is NOT "best practices": should all be private fields, and get/set methods. (Done this way so examples are shorter).

Fields Summary
private String
firstName
private String
lastName
public String
address
public String
phone
public String
Country
Constructors Summary
public Person(String f, String l)

		firstName = f;
		lastName = l;
	
Methods Summary
public java.lang.StringgetFirstName()

		return lastName;
	
public java.lang.StringgetLastName()

		return lastName;
	
public java.lang.StringgetName()

		return getFirstName() + ' " + getLastName();
	
public java.lang.StringtoString()

		return getName();