Package org.apache.pluto.driver.url

Examples of org.apache.pluto.driver.url.PortalURLParameter


       
        static PortalURLParameter createPortalURLParameter()
        {
            paramCount++;
           
            return new PortalURLParameter( windowId + paramCount,
                    paramName + paramCount,
                    paramValue + paramCount );
        }
View Full Code Here


    public void setParameters(Map parameters) {
        Iterator it = parameters.entrySet().iterator();
        while (it.hasNext()) {
            Map.Entry entry = (Map.Entry) it.next();
            PortalURLParameter param = new PortalURLParameter(
                window,
                (String) entry.getKey(),
                (String[]) entry.getValue());
            url.addParameter(param);
        }
View Full Code Here

    public void setParameters(Map parameters) {
        Iterator it = parameters.entrySet().iterator();
        while (it.hasNext()) {
            Map.Entry entry = (Map.Entry) it.next();
            PortalURLParameter param = new PortalURLParameter(
                window,
                (String) entry.getKey(),
                (String[]) entry.getValue());
            url.addParameter(param);
        }
View Full Code Here

        StringBuffer query = new StringBuffer("?");
        boolean firstParam = true;
        for (Iterator it = portalURL.getParameters().iterator();
            it.hasNext(); ) {

          PortalURLParameter param = (PortalURLParameter) it.next();

            // Encode action params in the query appended at the end of the URL.
            if (portalURL.getActionWindow() != null
                && portalURL.getActionWindow().equals(param.getWindowId())) {
                for (int i = 0; i < param.getValues().length; i++) {
                    // FIX for PLUTO-247
                    if ( firstParam ) {
                        firstParam = false;
                    } else {
                        query.append("&");
                    }
                    query.append(encodeQueryParam(param.getName())).append("=")
                        .append(encodeQueryParam(param.getValues()[i]));
                }
            }

            // Encode render params as a part of the URL.
            else if (param.getValues() != null
                && param.getValues().length > 0) {
                String valueString = encodeMultiValues(param.getValues());
                if (valueString.length() > 0) {
                  buffer.append("/").append(
                      encodeControlParameter(RENDER_PARAM, param.getWindowId(),
                               param.getName()));
                  buffer.append("/").append(valueString);
                }
            }
        }
View Full Code Here

        // Split multiple values into a value array.
        String[] paramValues = value.split(VALUE_DELIM);

        // Construct portal URL parameter and return.
        return new PortalURLParameter(windowId, paramName, paramValues);
    }
View Full Code Here

     * @param windowId  the window ID.
     */
    public void clearParameters(String windowId) {
      for (Iterator it = parameters.entrySet().iterator(); it.hasNext(); ) {
            Map.Entry entry = (Map.Entry) it.next();
            PortalURLParameter param = (PortalURLParameter) entry.getValue();
            if (param.getWindowId().equals(windowId)) {
              it.remove();
            }
        }
    }
View Full Code Here

                    value = st.nextToken();
                }

                // Defect PLUTO-361
                // ADDED
                PortalURLParameter param = decodeParameter( token, value );
                if( param != null )
                {
                    portalURL.addParameter( param );
                }
                // REMOVED
View Full Code Here

        StringBuffer query = new StringBuffer("?");
        boolean firstParam = true;
        for (Iterator it = portalURL.getParameters().iterator();
                it.hasNext(); ) {

            PortalURLParameter param = (PortalURLParameter) it.next();

            // Encode action params in the query appended at the end of the URL.
            if (portalURL.getActionWindow() != null
                    && portalURL.getActionWindow().equals(param.getWindowId())) {
                for (int i = 0; i < param.getValues().length; i++) {
                    // FIX for PLUTO-247
                    if ( firstParam ) {
                        firstParam = false;
                    } else {
                        query.append("&");
                    }
                    query.append(encodeQueryParam(param.getName())).append("=")
                            .append(encodeQueryParam(param.getValues()[i]));
                }
            }

            // Encode render params as a part of the URL.
            else if (param.getValues() != null
                    && param.getValues().length > 0) {
                String valueString = encodeMultiValues(param.getValues());
                if (valueString.length() > 0) {
                    buffer.append("/").append(
                            encodeControlParameter(RENDER_PARAM, param.getWindowId(),
                               param.getName()));
                    buffer.append("/").append(valueString);
                }
            }
        }
View Full Code Here

        for(int i=0;i<paramValues.length;i++) {
            paramValues[i] = decodeCharacters(paramValues[i]);
        }

        // Construct portal URL parameter and return.
        return new PortalURLParameter(windowId, paramName, paramValues);
    }
View Full Code Here

              value = st.nextToken();
            }

            // Defect PLUTO-361
            // ADDED
            PortalURLParameter param = decodeParameter( token, value );
            if( param != null )
            {
              portalURL.addParameter( param );
            }
            // REMOVED
View Full Code Here

TOP

Related Classes of org.apache.pluto.driver.url.PortalURLParameter

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.