|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.springframework.richclient.samples.simple.domain.Contact
public class Contact
This class provides a trivial domain object for the sample application. It represents a simple Contact entry in a personal address book. It is not very useful in that it only allows a single address for an individual and it doesn't support arbitrary contact data, just predefined fields. However, since we're not going into the Address Book business, this will suffice for demonstration purposes in this sample application.
This class makes use of one subordinate (or nested) object in order to show how nested property paths can be used in forms. It doesn't really serve any other great design need.
The validation rules for this class are provided externally, by SimpleValidationRulesSource
. This
configuration is often required when you don't have any mechanism to extend the domain object directly, or for other
design reasons, don't want to include the validation rules directly in the domain object implementation.
SimpleValidationRulesSource
Constructor Summary | |
---|---|
Contact()
Default constructor. |
Method Summary | |
---|---|
boolean |
equals(Object o)
Compare two objects for equality. |
Address |
getAddress()
|
ContactType |
getContactType()
|
Date |
getDateOfBirth()
|
String |
getEmailAddress()
|
String |
getFirstName()
|
String |
getHomePhone()
|
int |
getId()
|
String |
getLastName()
|
String |
getMiddleName()
|
String |
getWorkPhone()
|
int |
hashCode()
Hashcode. |
void |
setAddress(Address address)
|
void |
setContactType(ContactType contactType)
|
void |
setDateOfBirth(Date dateOfBirth)
|
void |
setEmailAddress(String emailAddress)
|
void |
setFirstName(String firstName)
|
void |
setHomePhone(String homePhone)
|
void |
setId(int id)
|
void |
setLastName(String lastName)
|
void |
setMiddleName(String middleName)
|
void |
setWorkPhone(String workPhone)
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Contact()
Method Detail |
---|
public int getId()
public void setId(int id)
id
- the id to setpublic Address getAddress()
public void setAddress(Address address)
address
- the address to setpublic Date getDateOfBirth()
public void setDateOfBirth(Date dateOfBirth)
dateOfBirth
- the dateOfBirth to setpublic String getEmailAddress()
public void setEmailAddress(String emailAddress)
emailAddress
- the emailAddress to setpublic String getFirstName()
public void setFirstName(String firstName)
firstName
- the firstName to setpublic String getHomePhone()
public void setHomePhone(String homePhone)
homePhone
- the homePhone to setpublic String getLastName()
public void setLastName(String lastName)
lastName
- the lastName to setpublic String getMiddleName()
public void setMiddleName(String middleName)
middleName
- the middleName to setpublic String getWorkPhone()
public void setWorkPhone(String workPhone)
workPhone
- the workPhone to setpublic ContactType getContactType()
public void setContactType(ContactType contactType)
contactType
- the contactType to setpublic boolean equals(Object o)
equals
in class Object
o
- object to comparepublic int hashCode()
hashCode
in class Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |