|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object
|
+--net.wimpi.pim.util.AbstractIdentifiable
|
+--net.wimpi.pim.contact.basicimpl.ContactImpl
A basic and simple implementation of a
Contact.
| Field Summary | |
protected java.util.List |
m_Addresses
|
protected java.util.List |
m_Categories
|
protected java.lang.String |
m_Classification
|
protected Communications |
m_Communications
|
protected Extensions |
m_Extensions
|
protected boolean |
m_Frequent
|
protected GeographicalInformation |
m_GeoInfo
|
protected Key |
m_Key
|
protected Address |
m_LastAddedAddress
|
protected java.lang.String |
m_Note
|
protected OrganizationalIdentity |
m_OrganizationalIdentity
|
protected PersonalIdentity |
m_PersonalIdentity
|
protected Address |
m_PreferredAddress
|
protected java.util.Date |
m_Revision
|
protected Sound |
m_Sound
|
protected java.lang.String |
m_Url
|
| Constructor Summary | |
ContactImpl()
|
|
| Method Summary | |
void |
addAddress(Address addr)
Adds an address to this Contact. |
void |
addCategory(java.lang.String category)
Adds a category to this Contact. |
java.lang.String |
getAccessClassification()
Returns the access classification of this Contact. |
Address |
getAddress(java.lang.String uid)
Returns the address at the given index. |
int |
getAddressCount()
Returns the number of addresses associated with this Contact. |
java.util.Iterator |
getAddresses()
Returns all addresses associated with this Contact. |
java.lang.String |
getCategoriesList()
|
java.lang.String |
getCategory(int index)
Returns the category at the given index. |
int |
getCategoryCount()
Returns the number of categories associated with this Contact. |
Communications |
getCommunications()
Returns the Communications instance associated with this Contact. |
java.util.Date |
getCurrentRevisionDate()
Returns the current revision date of this Contact. |
Extensions |
getExtensions()
Returns the extensions associated with this Contact. |
GeographicalInformation |
getGeographicalInformation()
Returns the GeographicalInformation instance associated with this Contact. |
Address |
getLastAddedAddress()
Returns the last added address. |
java.lang.String |
getNote()
Returns the note associated with this Contact. |
OrganizationalIdentity |
getOrganizationalIdentity()
Returns the OrganizationalIdentity of this Contact. |
PersonalIdentity |
getPersonalIdentity()
Returns the PersonalIdentity of this Contact. |
Address |
getPreferredAddress()
Returns the preferred address of this Contact instance. |
Key |
getPublicKey()
Returns the public key associated with this Contact. |
Sound |
getSound()
Returns the sound associated with this Contact. |
java.lang.String |
getURL()
Returns an URL associated with this Contact. |
boolean |
hasCommunications()
Tests if this Contact has a Communications instance. |
boolean |
hasExtensions()
Tests if this Contact has extensions. |
boolean |
hasGeographicalInformation()
Tests if this Contact has a GeographicalInformation instance. |
boolean |
hasOrganizationalIdentity()
Tests if this Contact has a OrganizationalIdentity. |
boolean |
hasPersonalIdentity()
Tests if this Contact has a PersonalIdentity. |
boolean |
hasPublicKey()
Tests if this Contact has a public key. |
boolean |
hasSound()
Tests if this Contact has a sound associated with it. |
boolean |
isFrequent()
Tests if this Contact is frequently used. |
boolean |
isPreferredAddress(Address address)
Tests if the given address is the preferred one of this Contact. |
Address[] |
listAddresses()
Returns all addresses associated with this Contact. |
Address[] |
listAddressesByType(int TYPE)
Returns the addresses of a given type of this Contact instance. |
java.lang.String[] |
listCategories()
Returns all categories of this this Contact. |
void |
removeAddress(Address addr)
Removes and returns the Address at the given index. |
void |
removeAllCategories()
Removes all categories. |
java.lang.String |
removeCategory(int index)
Removes and returns the category at the given index. |
void |
setAccessClassification(java.lang.String classification)
Sets the access classification of this Contact. |
void |
setCategoriesList(java.lang.String list)
|
java.lang.String |
setCategory(int index,
java.lang.String cat)
Sets the category at the given index, returning the replaced one. |
void |
setCommunications(Communications communications)
Sets the Communications instance associated with this Contact. |
void |
setCurrentRevisionDate(java.util.Date revision)
Sets the current revision date of this Contact. |
void |
setExtensions(Extensions extensions)
Sets the extensions associated with this Contact. |
void |
setFrequent(boolean b)
Sets the frequent flag of this Contact. |
void |
setGeographicalInformation(GeographicalInformation geoinfo)
Sets the GeographicalInformation instance associated with this Contact. |
void |
setNote(java.lang.String note)
Sets the note associated with this Contact. |
void |
setOrganizationalIdentity(OrganizationalIdentity identity)
Sets the OrganizationalIdentity of this Contact. |
void |
setPersonalIdentity(PersonalIdentity identity)
Sets the PersonalIdentity of this Contact. |
void |
setPreferredAddress(Address address)
Sets the preferred address of this Contact instance. |
void |
setPublicKey(Key key)
Sets the public key associated with this Contact. |
void |
setSound(Sound sound)
Sets the sound associated with this Contact. |
void |
setURL(java.lang.String url)
Sets the URL associated with this Contact. |
| Methods inherited from class net.wimpi.pim.util.AbstractIdentifiable |
equals, getUID, setUID |
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface net.wimpi.pim.util.Identifiable |
getUID |
| Field Detail |
protected java.lang.String m_Url
protected boolean m_Frequent
protected java.lang.String m_Note
protected java.util.Date m_Revision
protected java.lang.String m_Classification
protected java.util.List m_Addresses
protected java.util.List m_Categories
protected Address m_PreferredAddress
protected Address m_LastAddedAddress
protected PersonalIdentity m_PersonalIdentity
protected OrganizationalIdentity m_OrganizationalIdentity
protected Communications m_Communications
protected GeographicalInformation m_GeoInfo
protected Key m_Key
protected Sound m_Sound
protected Extensions m_Extensions
| Constructor Detail |
public ContactImpl()
| Method Detail |
public PersonalIdentity getPersonalIdentity()
Contact
getPersonalIdentity in interface Contactpublic void setPersonalIdentity(PersonalIdentity identity)
Contact
setPersonalIdentity in interface Contactidentity - a PersonalIdentity instance.public boolean hasPersonalIdentity()
Contact
hasPersonalIdentity in interface Contactpublic OrganizationalIdentity getOrganizationalIdentity()
Contact
getOrganizationalIdentity in interface Contactpublic void setOrganizationalIdentity(OrganizationalIdentity identity)
Contact
setOrganizationalIdentity in interface Contactidentity - an OrganizationalIdentity instance.public boolean hasOrganizationalIdentity()
Contact
hasOrganizationalIdentity in interface Contactpublic java.util.Iterator getAddresses()
Contact
getAddresses in interface Contactpublic Address[] listAddresses()
Contact
listAddresses in interface Contactpublic Address getAddress(java.lang.String uid)
Contact
getAddress in interface Contactuid - the unique identifier as String.
public Address getLastAddedAddress()
Contact
getLastAddedAddress in interface Contactpublic void addAddress(Address addr)
Contact
addAddress in interface Contactaddr - the Address to be added.
public void removeAddress(Address addr)
throws java.lang.IndexOutOfBoundsException
Contact
removeAddress in interface Contactaddr - the Address instance to be removed.
java.lang.IndexOutOfBoundsExceptionpublic Address getPreferredAddress()
Contact
getPreferredAddress in interface Contactpublic void setPreferredAddress(Address address)
Contact
setPreferredAddress in interface Contactaddress - the preferred address as Address.public boolean isPreferredAddress(Address address)
Contact
isPreferredAddress in interface Contactaddress - the address to be tested as Address.
public int getAddressCount()
Contact
getAddressCount in interface Contactpublic Address[] listAddressesByType(int TYPE)
Contact
listAddressesByType in interface ContactAddresspublic Communications getCommunications()
Contact
getCommunications in interface Contactpublic void setCommunications(Communications communications)
Contact
setCommunications in interface Contactcommunications - the Communications instance.public boolean hasCommunications()
Contact
hasCommunications in interface Contactpublic GeographicalInformation getGeographicalInformation()
Contact
getGeographicalInformation in interface Contactpublic void setGeographicalInformation(GeographicalInformation geoinfo)
Contact
setGeographicalInformation in interface Contactgeoinfo - the GeographicalInformation instance.public boolean hasGeographicalInformation()
Contact
hasGeographicalInformation in interface Contactpublic java.lang.String getCategoriesList()
public void setCategoriesList(java.lang.String list)
public java.lang.String[] listCategories()
Contact
listCategories in interface Contact
public java.lang.String getCategory(int index)
throws java.lang.IndexOutOfBoundsException
Contact
getCategory in interface Contactindex - the index as int.
java.lang.IndexOutOfBoundsException - if the index is
out of bounds.
public java.lang.String setCategory(int index,
java.lang.String cat)
Contact
setCategory in interface Contactindex - the index as int.cat - the category as String.
public void addCategory(java.lang.String category)
Contact
addCategory in interface Contactcategory - the category as String.
public java.lang.String removeCategory(int index)
throws java.lang.IndexOutOfBoundsException
Contact
removeCategory in interface Contactindex - the index as int.
java.lang.IndexOutOfBoundsException - if the index is
out of bounds.public void removeAllCategories()
Contact
removeAllCategories in interface Contactpublic int getCategoryCount()
Contact
getCategoryCount in interface Contactpublic java.lang.String getURL()
Contact
getURL in interface Contactpublic void setURL(java.lang.String url)
Contact
setURL in interface Contacturl - the URL as String.public boolean isFrequent()
Contact
isFrequent in interface Contactpublic void setFrequent(boolean b)
Contact
setFrequent in interface Contactb - true if frequent, false otherwise.public java.lang.String getNote()
Contact
getNote in interface Contactpublic void setNote(java.lang.String note)
Contact
setNote in interface Contactnote - the note as String.public java.util.Date getCurrentRevisionDate()
Contact
getCurrentRevisionDate in interface Contactpublic void setCurrentRevisionDate(java.util.Date revision)
Contact
setCurrentRevisionDate in interface Contactrevision - the revision date as Date.public java.lang.String getAccessClassification()
Contact
getAccessClassification in interface Contactpublic void setAccessClassification(java.lang.String classification)
Contact
setAccessClassification in interface Contactclassification - the access classification as String.public Key getPublicKey()
Contact
getPublicKey in interface Contactpublic void setPublicKey(Key key)
Contact
setPublicKey in interface Contactkey - the public key as Key.public boolean hasPublicKey()
Contact
hasPublicKey in interface Contactpublic Sound getSound()
Contact
getSound in interface Contactpublic void setSound(Sound sound)
Contact
setSound in interface Contactsound - the sound as Sound.public boolean hasSound()
Contact
hasSound in interface Contactpublic Extensions getExtensions()
Contact
getExtensions in interface Contactpublic void setExtensions(Extensions extensions)
Contact
setExtensions in interface Contactextensions - the extensions as Extensions instance.public boolean hasExtensions()
Contact
hasExtensions in interface Contact
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||