Package org.hdiv.urlProcessor

Examples of org.hdiv.urlProcessor.UrlData


      ExternalContext externalContext = context.getExternalContext();
      HttpServletRequest request = (HttpServletRequest) externalContext.getRequest();

      String url = component.getValue().toString();

      UrlData urlData = this.urlProcessor.createUrlData(url, "GET", request);
      if (this.urlProcessor.isHdivStateNecessary(urlData)) {

        boolean hasUIParams = UtilsJsf.hasUIParameterChild(component);

        // if url hasn't got parameters, we do not have to include HDIV's state
        if (!this.hdivConfig.isValidationInUrlsWithoutParamsActivated() && !urlData.containsParams()
            && !hasUIParams) {

          // Do nothing
          return;
        }

        IDataComposer dataComposer = HDIVUtil.getDataComposer(request);
        dataComposer.beginRequest("GET", urlData.getUrlWithoutContextPath());

        String processedParams = dataComposer.composeParams(urlData.getUrlParams(), "GET", Constants.ENCODING_UTF_8);
        urlData.setUrlParams(processedParams);

        if (hasUIParams) {

          for (UIComponent comp : component.getChildren()) {
            if (comp instanceof UIParameter) {
View Full Code Here


      ExternalContext externalContext = context.getExternalContext();
      HttpServletRequest request = (HttpServletRequest) externalContext.getRequest();

      String url = this.helper.getUrl(context, component);

      UrlData urlData = this.urlProcessor.createUrlData(url, "GET", request);
      if (this.urlProcessor.isHdivStateNecessary(urlData)) {

        boolean hasUIParams = UtilsJsf.hasUIParameterChild(component);

        // if url hasn't got parameters, we do not have to include HDIV's state
        if (!this.hdivConfig.isValidationInUrlsWithoutParamsActivated() && !urlData.containsParams()
            && !hasUIParams) {

          // Do nothing
          return;
        }

        IDataComposer dataComposer = HDIVUtil.getDataComposer(request);
        dataComposer.beginRequest("GET", urlData.getUrlWithoutContextPath());

        String processedParams = dataComposer.composeParams(urlData.getUrlParams(), "GET", Constants.ENCODING_UTF_8);
        urlData.setUrlParams(processedParams);

        String stateParam = dataComposer.endRequest();

        String hdivParameter = (String) externalContext.getSessionMap().get(Constants.HDIV_PARAMETER);
View Full Code Here

TOP

Related Classes of org.hdiv.urlProcessor.UrlData

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.