// of portletEntity and to replace the portletDefinition with one of current worker context.
// Refer to org.apache.jetspeed.components.portletentity.PortletEntityImpl class
curWindow = (PortletWindow)
CurrentWorkerContext.getAttribute(PortalReservedParameters.PORTLET_WINDOW_ATTRIBUTE);
PortletEntityImpl curEntity = (PortletEntityImpl) curWindow.getPortletEntity();
PortletDefinition oldPortletDefinition = curEntity.getPortletDefinition();
PortletDefinition curPortletDefinition = (PortletDefinition)
CurrentWorkerContext.getAttribute(PortalReservedParameters.PORTLET_DEFINITION_ATTRIBUTE);
if (!oldPortletDefinition.getId().equals(curPortletDefinition.getId())) {
curEntity.setPortletDefinition(curPortletDefinition);
}
}
}
this.request.setAttribute(PortalReservedParameters.FRAGMENT_ATTRIBUTE, fragment);