de.ix.jspTutorial.model
Class Customer

java.lang.Object
  |
  +--de.ix.jspTutorial.model.Customer

public class Customer
extends java.lang.Object
implements I_DatabaseObject

Definition of a pizza online shop customer

Version:
$Id:$
Author:
Peter Rossbach (pr@webapp.de), Lars Röwekamp ( lars.roewekamp@openKnowledge.de)

Field Summary
static java.lang.String vcid
          version of the source
 
Fields inherited from interface de.ix.jspTutorial.database.I_DatabaseObject
vcid
 
Constructor Summary
Customer()
          Constructor sets the id to -1 an all strings to the empty string.
Customer(long id, java.lang.String firstname, java.lang.String lastname, java.lang.String address1, java.lang.String address2, java.lang.String zip, java.lang.String town, java.lang.String eMail)
          Constructor to set all attributes of the customer.
 
Method Summary
 java.lang.String getAddress1()
          Getter method for the attribute address1
 java.lang.String getAddress2()
          Getter method for the attribute address2
 java.lang.String getEMail()
          Getter method for the attribute eMail
 java.lang.String getFirstname()
          Getter method for the attribute firstname
 DatabaseGenericObject getGenericObject()
          Method to create a generic object
 long getId()
          Getter method for the attribute id
 java.lang.String getLastname()
          Getter method for the attribute lastname
 java.lang.String getTown()
          Getter method for the attribute town
 java.lang.String getZip()
          Getter method for the attribute zip
 void set(Customer newCustomerValue)
          Set all attributes to the values of a second customer object.
 void setAddress1(java.lang.String newAddress1)
          Setter method for the attribute address1
 void setAddress2(java.lang.String newAddress2)
          Setter method for the attribute address2
 void setEmail(java.lang.String newEMail)
           
 void setEMail(java.lang.String newEMail)
          Setter method for the attribute eMail
 void setFirstname(java.lang.String newFirstname)
          Setter method for the attribute firstname
 void setId(long newId)
          Setter method for the attribute id
 void setLastname(java.lang.String newLastname)
          Setter method for the attribute lastname
 void setTown(java.lang.String newTown)
          Setter method for the attribute town
 void setZip(java.lang.String newZip)
          Setter method for the attribute zip
 java.lang.String toString()
          Build a string out of the customer attributes.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

vcid

public static java.lang.String vcid
version of the source
Constructor Detail

Customer

public Customer()
Constructor sets the id to -1 an all strings to the empty string.

Customer

public Customer(long id,
                java.lang.String firstname,
                java.lang.String lastname,
                java.lang.String address1,
                java.lang.String address2,
                java.lang.String zip,
                java.lang.String town,
                java.lang.String eMail)
Constructor to set all attributes of the customer.
Parameters:
firstname - Firstname
lastname - Lastname
address1 - First row of the address
address2 - Second row of the address
zip - zip code
town - town
eMail - current e-mail address
id - unique id
Method Detail

set

public void set(Customer newCustomerValue)
Set all attributes to the values of a second customer object.
Parameters:
newCustomerValue - new values for the customer

getGenericObject

public DatabaseGenericObject getGenericObject()
Method to create a generic object
Returns:
a DatabaseGenericObject
See Also:
DatabaseGenericModifier.create(I_DatabaseGenericObject,String)

setFirstname

public void setFirstname(java.lang.String newFirstname)
Setter method for the attribute firstname
Parameters:
newFirstname - new value for the attribute firstname
See Also:
getFirstname()

getFirstname

public java.lang.String getFirstname()
Getter method for the attribute firstname
Returns:
current value of the attribute firstname
See Also:
setFirstname(String)

setLastname

public void setLastname(java.lang.String newLastname)
Setter method for the attribute lastname
Parameters:
newLastname - new value for the attribute lastname
See Also:
getLastname()

getLastname

public java.lang.String getLastname()
Getter method for the attribute lastname
Returns:
current value of the attribute lastname
See Also:
setLastname(String)

setAddress1

public void setAddress1(java.lang.String newAddress1)
Setter method for the attribute address1
Parameters:
newFirstname - new value for the attribute address1
See Also:
getAddress1()

getAddress1

public java.lang.String getAddress1()
Getter method for the attribute address1
Returns:
current value of the attribute address1
See Also:
setAddress1(String)

setAddress2

public void setAddress2(java.lang.String newAddress2)
Setter method for the attribute address2
Parameters:
newAddress - new value for the attribute address2
See Also:
getAddress2()

getAddress2

public java.lang.String getAddress2()
Getter method for the attribute address2
Returns:
current value of the attribute address2
See Also:
setAddress2(String)

setZip

public void setZip(java.lang.String newZip)
Setter method for the attribute zip
Parameters:
newZip - new value for the attribute zip
See Also:
getZip()

getZip

public java.lang.String getZip()
Getter method for the attribute zip
Returns:
current value of the attribute zip
See Also:
setZip(String)

setTown

public void setTown(java.lang.String newTown)
Setter method for the attribute town
Parameters:
newTown - new value for the attribute town
See Also:
getTown()

getTown

public java.lang.String getTown()
Getter method for the attribute town
Returns:
current value of the attribute town
See Also:
setTown(String)

setEmail

public void setEmail(java.lang.String newEMail)

setEMail

public void setEMail(java.lang.String newEMail)
Setter method for the attribute eMail
Parameters:
newEMail - new value for the attribute eMail
See Also:
getEMail()

getEMail

public java.lang.String getEMail()
Getter method for the attribute eMail
Returns:
current value of the attribute eMail
See Also:
setEMail(String)

setId

public void setId(long newId)
Setter method for the attribute id
Parameters:
newId - new value for the attribute id
See Also:
getId()

getId

public long getId()
Getter method for the attribute id
Returns:
current value of the attribute id
See Also:
setId(long)

toString

public java.lang.String toString()
Build a string out of the customer attributes.
Overrides:
toString in class java.lang.Object
Returns:
String representation of the customer


~ Das iX JSP Tutorial II - © 2000 by Peter Roßbach ~