Package org.gatein.pc.api

Examples of org.gatein.pc.api.RenderURL


            Mode mode = resourceURL.getMode();
            if (mode != null) {
                url.setQueryParameterValue(Constants.PORTLET_MODE_PARAMETER, mode.toString());
            }
        } else {
            RenderURL renderURL = (RenderURL) containerURL;

            WindowState windowState = renderURL.getWindowState();
            if (windowState != null)// && !windowState.equals(WindowState.NORMAL))
            {
                url.setQueryParameterValue(Constants.WINDOW_STATE_PARAMETER, windowState.toString());
            }

            Mode mode = renderURL.getMode();
            if (mode != null) {
                url.setQueryParameterValue(Constants.PORTLET_MODE_PARAMETER, mode.toString());
            }

            Map<String, String[]> publicNSChanges = renderURL.getPublicNavigationalStateChanges();
            if (ParameterValidation.existsAndIsNotEmpty(publicNSChanges)) {
                for (String key : publicNSChanges.keySet()) {
                    String[] values = publicNSChanges.get(key);
                    if (values != null && values.length > 0) {
                        for (String value : values) {
                            url.setQueryParameterValue(key, value);
                        }
                    } else {
                        url.setQueryParameterValue("removePP", key);
                    }
                }
            }

            StateString state = renderURL.getNavigationalState();
            if (state != null && !state.getStringValue().equals(StateString.JBPNS_PREFIX)) {
                url.setQueryParameterValue(NAVIGATIONAL_STATE_PARAM_NAME, state.getStringValue());
            }
        }
View Full Code Here


            StateString interactionState = actionURL.getInteractionState();
            parameters.put(ControllerRequestParameterNames.INTERACTION_STATE, interactionState.getStringValue());
         }
         else
         {
            RenderURL renderURL = (RenderURL)containerURL;

            //
            Map<String, String[]> changes = renderURL.getPublicNavigationalStateChanges();
            byte[] bytes = IOTools.serialize(Serialization.PARAMETER_MAP, SerializationFilter.COMPRESSOR, changes);
            String ns = Base64.encodeBytes(bytes, Base64.EncodingOption.USEURLSAFEENCODING);
            parameters.put(ControllerRequestParameterNames.PUBLIC_NAVIGATIONAL_STATE_CHANGES, ns);

            //
            StateString navigationalState = renderURL.getNavigationalState();
            if (navigationalState != null)
            {
               parameters.put(ControllerRequestParameterNames.NAVIGATIONAL_STATE, navigationalState.getStringValue());
            }
         }
View Full Code Here

            appendParameter(baseURL, Constants.PORTLET_MODE_PARAMETER, mode.toString());
         }
      }
      else
      {
         RenderURL renderURL = (RenderURL)containerURL;

         WindowState windowState = renderURL.getWindowState();
         if (windowState != null)//&& !windowState.equals(WindowState.NORMAL))
         {
            appendParameter(baseURL, Constants.WINDOW_STATE_PARAMETER, windowState.toString());
         }

         Mode mode = renderURL.getMode();
         if (mode != null && !mode.equals(Mode.VIEW))
         {
            appendParameter(baseURL, Constants.PORTLET_MODE_PARAMETER, mode.toString());
         }

         Map<String, String[]> publicNSChanges = renderURL.getPublicNavigationalStateChanges();
         if (ParameterValidation.existsAndIsNotEmpty(publicNSChanges))
         {
            for (String key : publicNSChanges.keySet())
            {
               String[] values = publicNSChanges.get(key);
               if (values != null && values.length > 0)
               {
                  for (String value : values)
                  {
                     appendParameter(baseURL, key, value);
                  }
               }
               else
               {
                  appendParameter(baseURL, "removePP", key);
               }
            }
         }

         StateString state = renderURL.getNavigationalState();
         if (state != null && !state.getStringValue().equals(StateString.JBPNS_PREFIX))
         {
            appendParameter(baseURL, NAVIGATIONAL_STATE_PARAM_NAME, state.getStringValue());
         }
      }
View Full Code Here

            StateString interactionState = actionURL.getInteractionState();
            parameters.put(ControllerRequestParameterNames.INTERACTION_STATE, interactionState.getStringValue());
         }
         else
         {
            RenderURL renderURL = (RenderURL)containerURL;

            //
            Map<String, String[]> changes = renderURL.getPublicNavigationalStateChanges();
            byte[] bytes = IOTools.serialize(Serialization.PARAMETER_MAP, SerializationFilter.COMPRESSOR, changes);
            String ns = Base64.encodeBytes(bytes, Base64.EncodingOption.USEURLSAFEENCODING);
            parameters.put(ControllerRequestParameterNames.PUBLIC_NAVIGATIONAL_STATE_CHANGES, ns);

            //
            StateString navigationalState = renderURL.getNavigationalState();
            if (navigationalState != null)
            {
               parameters.put(ControllerRequestParameterNames.NAVIGATIONAL_STATE, navigationalState.getStringValue());
            }
         }
View Full Code Here

            StateString interactionState = actionURL.getInteractionState();
            parameters.put(ControllerRequestParameterNames.INTERACTION_STATE, interactionState.getStringValue());
         }
         else
         {
            RenderURL renderURL = (RenderURL)containerURL;

            //
            Map<String, String[]> changes = renderURL.getPublicNavigationalStateChanges();
            byte[] bytes = IOTools.serialize(Serialization.PARAMETER_MAP, SerializationFilter.COMPRESSOR, changes);
            String ns = Base64.encodeBytes(bytes, Base64.EncodingOption.USEURLSAFEENCODING);
            parameters.put(ControllerRequestParameterNames.PUBLIC_NAVIGATIONAL_STATE_CHANGES, ns);

            //
            StateString navigationalState = renderURL.getNavigationalState();
            if (navigationalState != null)
            {
               parameters.put(ControllerRequestParameterNames.NAVIGATIONAL_STATE, navigationalState.getStringValue());
            }
         }
View Full Code Here

            StateString interactionState = actionURL.getInteractionState();
            parameters.put(ControllerRequestParameterNames.INTERACTION_STATE, interactionState.getStringValue());
         }
         else
         {
            RenderURL renderURL = (RenderURL)containerURL;

            //
            Map<String, String[]> changes = renderURL.getPublicNavigationalStateChanges();
            byte[] bytes = IOTools.serialize(Serialization.PARAMETER_MAP, SerializationFilter.COMPRESSOR, changes);
            String ns = Base64.encodeBytes(bytes, true);
            parameters.put(ControllerRequestParameterNames.PUBLIC_NAVIGATIONAL_STATE_CHANGES, ns);

            //
            StateString navigationalState = renderURL.getNavigationalState();
            if (navigationalState != null)
            {
               parameters.put(ControllerRequestParameterNames.NAVIGATIONAL_STATE, navigationalState.getStringValue());
            }
         }
View Full Code Here

         context.getPageNavigationalStateSerialization());

      final org.gatein.pc.api.WindowState ws = windowState;
      final org.gatein.pc.api.Mode md = mode;

      RenderURL url = new RenderURL()
      {


         public StateString getNavigationalState()
         {
View Full Code Here

TOP

Related Classes of org.gatein.pc.api.RenderURL

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.