* correct type based on the type of the IResource it is for.
* @param targetResource
* @return subtype of BasePage for the specific targetResource
*/
private BasePage generateResponsePage(IResource targetResource) {
BasePage targetClass = null;
if (targetResource instanceof IProject) {
targetClass = new ProjectDetailPage((IProject) targetResource);
} else if (targetResource instanceof IPerson) {
targetClass = new PersonDetailPage((IPerson) targetResource);