edu.jhu.cs.oose.group3.intelligentbook.backingbeans
Class AddContactBackingBean

java.lang.Object
  extended by edu.jhu.cs.oose.group3.intelligentbook.backingbeans.SuperBackingBean
      extended by edu.jhu.cs.oose.group3.intelligentbook.backingbeans.SessionBackingBean
          extended by edu.jhu.cs.oose.group3.intelligentbook.backingbeans.AddContactBackingBean
Direct Known Subclasses:
AddBasicInfoBackingBean, AddPersonalAddressesBackingBean, AddPersonalInfoBackingBean, AddWorkAddressesBackingBean, AddWorkInfoBackingBean

public abstract class AddContactBackingBean
extends SessionBackingBean

This class is the superclass for all AddContact backing beans. It provides contact service for updating contact in the database as well as miscellaneous information for filling a form.


Field Summary
private  ContactItemKeys contactItemKeys
          Set the implementation of ContactItemKeys, used for identifying ContactItems
private  ContactService contactService
          allows save/update contact
private static java.util.List<javax.faces.model.SelectItem> states
           
 
Constructor Summary
AddContactBackingBean()
           
 
Method Summary
 java.util.List<javax.faces.model.SelectItem> getAllContactGroups()
          Get all the visibility contact groups from the current user
 java.util.List<javax.faces.model.SelectItem> getAllStates()
          Get all states as a list of Select Items to be used in the form
 ContactItemKeys getContactItemKeys()
          Get the implementation of ContactItemKeys, used for identifying ContactItems
 ContactService getContactService()
          Get the current contact service, used to update contacts in the database
 void setContactItemKeys(ContactItemKeys contactItemKeys)
          Set the implementation of ContactItemKeys, used for identifying ContactItems
 void setContactService(ContactService contactService)
          Set the current contact service, used to update contacts in the database
abstract  java.lang.String updateContact()
          Update/save the contact information
 
Methods inherited from class edu.jhu.cs.oose.group3.intelligentbook.backingbeans.SessionBackingBean
getAllEnumeratedGroups, getCurrentUser, setCurrentUser
 
Methods inherited from class edu.jhu.cs.oose.group3.intelligentbook.backingbeans.SuperBackingBean
getErrors, getNotices, setErrors, setNotices
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

contactItemKeys

private ContactItemKeys contactItemKeys
Set the implementation of ContactItemKeys, used for identifying ContactItems


contactService

private ContactService contactService
allows save/update contact


states

private static java.util.List<javax.faces.model.SelectItem> states
Constructor Detail

AddContactBackingBean

public AddContactBackingBean()
Method Detail

updateContact

public abstract java.lang.String updateContact()
Update/save the contact information

Returns:
update status

getContactItemKeys

public ContactItemKeys getContactItemKeys()
Get the implementation of ContactItemKeys, used for identifying ContactItems

Returns:
the implementation of ContactItemKeys, used for identifying ContactItems

setContactItemKeys

public void setContactItemKeys(ContactItemKeys contactItemKeys)
Set the implementation of ContactItemKeys, used for identifying ContactItems

Parameters:
contactItemKeys - the implementation of ContactItemKeys, used for identifying ContactItems

getContactService

public ContactService getContactService()
Get the current contact service, used to update contacts in the database

Returns:
the current contact service

setContactService

public void setContactService(ContactService contactService)
Set the current contact service, used to update contacts in the database

Parameters:
contactService - the contact service

getAllContactGroups

public java.util.List<javax.faces.model.SelectItem> getAllContactGroups()
Get all the visibility contact groups from the current user

Returns:
all the contact groups from the current user

getAllStates

public java.util.List<javax.faces.model.SelectItem> getAllStates()
Get all states as a list of Select Items to be used in the form

Returns:
all states as a list of SelectItems to be used in the form