org.ow2.dragon.ui.uibeans.organization
Class ListOfPersonsBean

java.lang.Object
  extended by org.ow2.dragon.ui.uibeans.organization.ListOfPersonsBean

public class ListOfPersonsBean
extends java.lang.Object

This bean holds a list of persons. It is initialized either by loading all persons from the database, or by searching persons by name.

This version of the bean performs the search when loading, then lets the framework manage sort and pagination. This design may only be used if you're sure the amount of data is "reasonable" and under control.

Author:
ambarthe, ofabre

Constructor Summary
ListOfPersonsBean()
           
 
Method Summary
 java.util.List<org.ow2.dragon.api.to.organization.PersonTO> getPersons()
           
 java.util.List<org.ow2.dragon.api.to.organization.PersonTO> getPersonsToLink()
           
 java.lang.String getSearchCriteria()
           
 java.util.List<java.lang.String> getSearchedProperties()
           
 void loadAll()
          Loads all persons from the database
 void loadByOrganization(java.lang.String orgId)
          Loads all the persons of an organization from the database
 void search(javax.servlet.http.HttpServletRequest request)
          Searches persons by firstname, lastname, location, organisation, post
 void setSearchCriteria(java.lang.String searchCriteria)
           
 void setSearchedProperties(java.util.List<java.lang.String> searchedProperties)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ListOfPersonsBean

public ListOfPersonsBean()
Method Detail

loadAll

public void loadAll()
             throws org.ow2.opensuit.core.error.LocalizedError
Loads all persons from the database

Throws:
org.ow2.opensuit.core.error.LocalizedError

loadByOrganization

public void loadByOrganization(java.lang.String orgId)
                        throws org.ow2.opensuit.core.error.LocalizedError
Loads all the persons of an organization from the database

Throws:
org.ow2.opensuit.core.error.LocalizedError

getPersonsToLink

public java.util.List<org.ow2.dragon.api.to.organization.PersonTO> getPersonsToLink()

search

public void search(javax.servlet.http.HttpServletRequest request)
            throws org.ow2.opensuit.core.error.LocalizedError
Searches persons by firstname, lastname, location, organisation, post

Throws:
org.ow2.opensuit.core.error.LocalizedError

getSearchCriteria

public java.lang.String getSearchCriteria()
Returns:
the searchCriteria

getPersons

public java.util.List<org.ow2.dragon.api.to.organization.PersonTO> getPersons()

setSearchCriteria

public void setSearchCriteria(java.lang.String searchCriteria)
Parameters:
searchCriteria - the searchCriteria to set

getSearchedProperties

public java.util.List<java.lang.String> getSearchedProperties()

setSearchedProperties

public void setSearchedProperties(java.util.List<java.lang.String> searchedProperties)


Copyright © 2008-2010 eBMWebsourcing. All Rights Reserved.