org.scubatoolkit
Class Person

java.lang.Object
  |
  +--org.scubatoolkit.Person

public class Person
extends java.lang.Object

Description of the Class * * @author * @version


Field Summary
private  ContactInfo contactInfo
           
private  java.lang.String firstName
           
private  java.lang.String lastName
           
private  int personID
           
 
Constructor Summary
Person()
          Constructor for the Person object * * @param fname Description of the Parameter * @param lname Description of the Parameter
 
Method Summary
private  int createPerson()
           
 ContactInfo getContactInfo()
           
 java.lang.String getFirstName()
          Gets the firstName attribute of the Person object * * @return The firstName value
 java.lang.String getLastName()
          Gets the lastName attribute of the Person object * * @return The lastName value
 int getPersonID()
           
static java.util.Vector getPersons()
           
static Person loadPerson(int personID)
           
static void remove(Person person)
           
 int save()
           
 void setContactInfo(ContactInfo info)
           
 void setFirstName(java.lang.String fname)
          Sets the firstName attribute of the Person object * * @param fname The new firstName value
 void setLastName(java.lang.String lname)
          Sets the lastName attribute of the Person object * * @param lname The new lastName value
 void setPersonID(int ID)
           
 java.lang.String toString()
           
private  int updatePerson()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

contactInfo

private ContactInfo contactInfo

firstName

private java.lang.String firstName

lastName

private java.lang.String lastName

personID

private int personID
Constructor Detail

Person

public Person()
Constructor for the Person object * * @param fname Description of the Parameter * @param lname Description of the Parameter

Method Detail

getPersons

public static java.util.Vector getPersons()
                                   throws java.lang.ClassNotFoundException,
                                          java.sql.SQLException
java.lang.ClassNotFoundException
java.sql.SQLException

loadPerson

public static Person loadPerson(int personID)
                         throws java.lang.ClassNotFoundException,
                                java.sql.SQLException
java.lang.ClassNotFoundException
java.sql.SQLException

remove

public static void remove(Person person)
                   throws java.lang.ClassNotFoundException,
                          java.sql.SQLException
java.lang.ClassNotFoundException
java.sql.SQLException

getContactInfo

public ContactInfo getContactInfo()
Returns:

getFirstName

public java.lang.String getFirstName()
Gets the firstName attribute of the Person object * * @return The firstName value


getLastName

public java.lang.String getLastName()
Gets the lastName attribute of the Person object * * @return The lastName value


getPersonID

public int getPersonID()

save

public int save()
         throws java.lang.ClassNotFoundException,
                java.sql.SQLException
java.lang.ClassNotFoundException
java.sql.SQLException

setContactInfo

public void setContactInfo(ContactInfo info)
Parameters:
info -

setFirstName

public void setFirstName(java.lang.String fname)
Sets the firstName attribute of the Person object * * @param fname The new firstName value


setLastName

public void setLastName(java.lang.String lname)
Sets the lastName attribute of the Person object * * @param lname The new lastName value


setPersonID

public void setPersonID(int ID)

createPerson

private int createPerson()
                  throws java.lang.ClassNotFoundException,
                         java.sql.SQLException
java.lang.ClassNotFoundException
java.sql.SQLException

updatePerson

private int updatePerson()
                  throws java.lang.ClassNotFoundException,
                         java.sql.SQLException
java.lang.ClassNotFoundException
java.sql.SQLException

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object


Copyright © 2002 The Scuba Toolkit Team. All Rights Reserved.