Package javax.portlet

Examples of javax.portlet.ActionRequest


        // add the cocoon header timestamp
        res.setProperty("X-Cocoon-Version", Constants.VERSION);

        // get the request (wrapped if contains multipart-form data)
        ActionRequest request;
        try {
            if (this.enableUploads) {
                request = requestFactory.getServletRequest(req);
            } else {
                request = req;
View Full Code Here


        // add the cocoon header timestamp
        res.setProperty("X-Cocoon-Version", Constants.VERSION);

        // get the request (wrapped if contains multipart-form data)
        ActionRequest request;
        try {
            if (this.enableUploads) {
                request = requestFactory.getServletRequest(req);
            } else {
                request = req;
            }
        } catch (Exception e) {
            if (getLogger().isErrorEnabled()) {
                getLogger().error("Problem with Cocoon portlet", e);
            }

            manageException(req, res, null, null,
                            "Problem in creating the Request", null, null, e);
            return;
        }

        // Get the cocoon engine instance
        getCocoon(request.getParameter(Constants.RELOAD_PARAM));

        // Check if cocoon was initialized
        if (this.cocoon == null) {
            manageException(request, res, null, null,
                            "Initialization Problem",
View Full Code Here

     * methods that allow easier connection to those objects since the servlet
     * API doesn't provide those methods directly.
     */
    public ActionRequest getServletRequest(ActionRequest request)
    throws IOException, MultipartException {
        ActionRequest req = request;
        String contentType = request.getContentType();

        if ((contentType != null) && (contentType.toLowerCase().indexOf("multipart/form-data") > -1)) {
            if (request.getContentLength() > maxUploadSize) {
                throw new IOException("Content length exceeds maximum upload size.");
View Full Code Here

     * @see org.apache.pluto.factory.ActionRequestFactory#getActionRequest(org.apache.pluto.om.window.PortletWindow, javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)
     */
    public ActionRequest getActionRequest(PortletWindow       portletWindow,
                                          HttpServletRequest  servletRequest,
                                          HttpServletResponse servletResponse) {
        ActionRequest actionRequest = new ActionRequestImpl(portletWindow, servletRequest, this.portalService.getComponentManager().getProfileManager().getUser());
        return actionRequest;
    }
View Full Code Here

        // add the cocoon header timestamp
        res.setProperty("X-Cocoon-Version", Constants.VERSION);

        // get the request (wrapped if contains multipart-form data)
        ActionRequest request;
        try {
            if (this.enableUploads) {
                request = requestFactory.getServletRequest(req);
            } else {
                request = req;
View Full Code Here

        // add the cocoon header timestamp
        res.setProperty("X-Cocoon-Version", Constants.VERSION);

        // get the request (wrapped if contains multipart-form data)
        ActionRequest request;
        try {
            if (this.enableUploads) {
                request = requestFactory.getServletRequest(req);
            } else {
                request = req;
            }
        } catch (Exception e) {
            if (getLogger().isErrorEnabled()) {
                getLogger().error("Problem with Cocoon portlet", e);
            }

            manageException(req, res, null, null,
                            "Problem in creating the Request", null, null, e);
            return;
        }

        // Get the cocoon engine instance
        getCocoon(request.getParameter(Constants.RELOAD_PARAM));

        // Check if cocoon was initialized
        if (this.cocoon == null) {
            manageException(request, res, null, null,
                            "Initialization Problem",
View Full Code Here

  protected void doActionService(ActionRequest request, ActionResponse response) throws Exception {
    if (logger.isDebugEnabled()) {
      logger.debug("DispatcherPortlet with name '" + getPortletName() + "' received action request");
    }

    ActionRequest processedRequest = request;
    HandlerExecutionChain mappedHandler = null;
    int interceptorIndex = -1;

    try {
      processedRequest = checkMultipart(request);
View Full Code Here

    }
  }

  public void testActionRequestNotHandled() throws Exception {
    ParameterizableViewController controller = new ParameterizableViewController();
    ActionRequest request = new MockActionRequest();
    ActionResponse response = new MockActionResponse();
    try {
      controller.handleActionRequest(request, response);
      fail("should have thrown PortletException");
    }
View Full Code Here

        return (IPortletWindowId)portletSession.getAttribute(RenderPortletTag.DEFAULT_SESSION_KEY_PREFIX + fname);
  }
 
  public boolean configModeAction(ExternalContext externalContext, String fname) throws IOException {

      final ActionRequest actionRequest = (ActionRequest)externalContext.getNativeRequest();
      final ActionResponse actionResponse = (ActionResponse)externalContext.getNativeResponse();

      final IPortletWindowId portletWindowId = this.getDelegateWindowId(externalContext, fname);
      if (portletWindowId == null) {
          throw new IllegalStateException("Cannot execute configModeAciton without a delegate window ID in the session for key: " + RenderPortletTag.DEFAULT_SESSION_KEY_PREFIX + fname);
View Full Code Here

        }

        String location = null;

        InternalActionResponse _actionResponse = null;
        ActionRequest actionRequest = null;

        try
        {
            /*ActionRequest*/
            actionRequest =
View Full Code Here

TOP

Related Classes of javax.portlet.ActionRequest

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.