public EventRequestImpl(PortletRequestContext requestContext, PortletEventResponseContext responseContext, Event event)
{
super(requestContext, responseContext, PortletRequest.EVENT_PHASE);
this.event = event;
}
java类javax.portlet.Event的实例源码
EventRequestImpl.java 文件源码
项目:portals-pluto
阅读 17
收藏 0
点赞 0
评论 0
EventRequestImpl.java 文件源码
项目:portals-pluto
阅读 18
收藏 0
点赞 0
评论 0
public Event getEvent()
{
return event;
}
PortletEnvironmentServiceImpl.java 文件源码
项目:portals-pluto
阅读 17
收藏 0
点赞 0
评论 0
public EventRequest createEventRequest(PortletRequestContext requestContext, PortletEventResponseContext responseContext, Event event)
{
return new EventRequestImpl(requestContext, responseContext, event);
}
MockEventRequest.java 文件源码
项目:portals-pluto
阅读 20
收藏 0
点赞 0
评论 0
@Override
public Event getEvent() {
return new MockEvent(qn);
}
EventCoordinationServiceImpl.java 文件源码
项目:portals-pluto
阅读 16
收藏 0
点赞 0
评论 0
public void processEvents(PortletContainer container,
PortletWindow portletWindow, HttpServletRequest request,
HttpServletResponse response, List<Event> events) {
ServletContext containerServletContext = PortalRequestContext.getContext(
request).getServletContext();
DriverConfiguration driverConfig = (DriverConfiguration) containerServletContext
.getAttribute(AttributeKeys.DRIVER_CONFIG);
// PortalURL portalURL = PortalURLParserImpl.getParser().parse(request);
PortalURL portalURL = PortalRequestContext.getContext(request)
.createPortalURL();
// Map<String, PortletWindowThread> portletWindowThreads = new
// HashMap<String, PortletWindowThread>();
// ThreadGroup threadGroup = new ThreadGroup("FireEventThreads");
for (Event event : events) {
List<String> portletNames = getAllPortletsRegisteredForEvent(event,
driverConfig, containerServletContext, portalURL);
// Deliver events to all portlets in the portal
// Collection<PortletWindowConfig> portlets =
// getAllPortlets(driverConfig);
// Limit event delivery to portlets that are on the current page
Collection<PortletWindowConfig> portlets = new ArrayList<PortletWindowConfig>();
for (String pid : portalURL.getPortletIds()) {
portlets.add(PortletWindowConfig.fromId(pid));
}
// iterate all portlets in the portal
for (PortletWindowConfig config : portlets) {
PortletWindow window = new PortletWindowImpl(container, config,
portalURL);
if (portletNames != null) {
for (String portlet : portletNames) {
if (portlet.equals(config.getId())) {
/*
* PLUTO-569: multi-threaded (event) request processing
* isn't thread save with the Pluto Portal Driver handling
* of request attributes as they all are stored/managed
* within the single underlying HttpServletRequest.
* Providing proper thread save parallel request processing
* would require extensive enhancements to the Pluto Portal
* Driver and as such is out-of-scope for the purpose of
* the Portal Driver itself.
*
* // the thread now is a new one, with possible //
* waiting, // for the old to exit
*
*
* PortletWindowThread portletWindowThread =
* getPortletWindowThread(portletWindowThreads,
* threadGroup, container, config, window, request,
* response, containerServletContext);
*
* // is this event portletWindowThread.addEvent(event);
*
* portletWindowThread.start();
*
* } } } } waitForEventExecution(threadGroup); try {
* Thread.sleep(WAITING_CYCLE); } catch
* (InterruptedException e) { LOG.warn(e.getMessage(),e); }
* } waitForEventExecution(threadGroup);
*/
doEvent(container, window, event, request, response);
}
}
}
}
}
}
PortletWindowThread.java 文件源码
项目:portals-pluto
阅读 16
收藏 0
点赞 0
评论 0
public void addEvent(Event event) {
this.events.add(event);
}
MockEventRequest.java 文件源码
项目:spring4-understanding
阅读 19
收藏 0
点赞 0
评论 0
/**
* Create a new MockEventRequest with a default {@link MockPortalContext}
* and a default {@link MockPortletContext}.
* @param event the event that this request wraps
* @see MockEvent
*/
public MockEventRequest(Event event) {
super();
this.event = event;
}
MockEventRequest.java 文件源码
项目:spring4-understanding
阅读 18
收藏 0
点赞 0
评论 0
/**
* Create a new MockEventRequest with a default {@link MockPortalContext}.
* @param event the event that this request wraps
* @param portletContext the PortletContext that the request runs in
* @see MockEvent
*/
public MockEventRequest(Event event, PortletContext portletContext) {
super(portletContext);
this.event = event;
}
MockEventRequest.java 文件源码
项目:spring4-understanding
阅读 18
收藏 0
点赞 0
评论 0
/**
* Create a new MockEventRequest.
* @param event the event that this request wraps
* @param portalContext the PortletContext that the request runs in
* @param portletContext the PortletContext that the request runs in
*/
public MockEventRequest(Event event, PortalContext portalContext, PortletContext portletContext) {
super(portalContext, portletContext);
this.event = event;
}
MockEventRequest.java 文件源码
项目:spring4-understanding
阅读 21
收藏 0
点赞 0
评论 0
/**
* Create a new MockEventRequest with a default {@link MockPortalContext}
* and a default {@link MockPortletContext}.
* @param event the event that this request wraps
* @see MockEvent
*/
public MockEventRequest(Event event) {
super();
this.event = event;
}