Package javax.servlet.jsp

Examples of javax.servlet.jsp.JspException


        }
        results.append(">");
        Object value = TagUtils.getInstance().lookup(pageContext, modelName, modelProperty,
            null);
        if (value == null || ! ( value instanceof MultiSelectSelectionModel )) {
            throw new JspException("Model attributes must specify an instance of MultiSelectListDataSourceModel (" + value + ")");
        }
        MultiSelectSelectionModel model = (MultiSelectSelectionModel)value;
        for(Iterator i = model.getSelectedValues().iterator(); i.hasNext(); ) {
            LabelValueBean lvb = (LabelValueBean)i.next();
            results.append("<option value=\"");
View Full Code Here


      s.append("No validation result.");
    }
    try {
      pageContext.getOut().print(s.toString());
    } catch (IOException e) {
      throw new JspException(e);
    }
    return EVAL_PAGE;
  }
View Full Code Here

  protected void init() throws Exception {
    super.init();

    groupTag = (GroupTag)findAncestor(GroupTag.class);
    if (groupTag == null) {
      throw new JspException("A " + getTypeAttribute() + "item tag must be nested in a group tag!");
    }

    checkValue();
    checkMultiple();
  }
View Full Code Here

          in = new URL(url).openStream();
          Util.copy(in, baos);
          TagUtils.getInstance().write(pageContext, new String(baos.toByteArray()));
      }
      catch(IOException ioe) {
          throw new JspException("Failed to load external page.", ioe);
      }
      finally {
          Util.closeStream(in);
          Util.closeStream(baos);
      }
View Full Code Here

                for (int i = 0; i < tiles; i++) {
                    TilesUtil.doInclude("/WEB-INF/theme/default/blankActionLink.jspf", pageContext);
                }
            } catch (IOException e1) {
                e1.printStackTrace();
                throw new JspException(e1);
            } catch (ServletException e2) {
                e2.printStackTrace();
                throw new JspException(e2);
            }
        }
        else{
            TagUtils
            .getInstance()
View Full Code Here

        }
        JspWriter writer = pageContext.getOut();
        try {
            writer.print(results.toString());
        } catch (IOException e) {
            throw new JspException(messages.getMessage("common.io", e.toString()));
        }
        return (EVAL_PAGE);
    }
View Full Code Here

   * @exception JspException if a JSP exception has occurred
   */
  public int doStartTag() throws JspException {

    if (action == null) {
      throw new JspException("action attribute required");
    }

    if (linkname == null) {
      throw new JspException("linkname attribute required");
    }

    return (SKIP_BODY);
  }
View Full Code Here

     */
    public int doStartTag() throws JspException {

        Object value = TagUtils.getInstance().lookup(pageContext, name, property, null);
        if (value == null || !(value instanceof TabModel)) {
            throw new JspException("Name / property attributes must specify an instance of TabModel (" + value + ")");
        }
        model = (TabModel) value;
        return (EVAL_BODY_BUFFERED);
    }
View Full Code Here

     * @see org.apache.struts.taglib.html.BaseFieldTag#doStartTag()
     */
    public int doStartTag() throws JspException {
        Object value = findAncestorWithClass(this, TabSetTag.class);
        if (value == null) {
            throw new JspException("TabTag must be contained in a TabSetTag");
        }
        model = ((TabSetTag) value).getModel();
        text = null;
        return EVAL_BODY_BUFFERED;
    }
View Full Code Here

     * @see org.apache.struts.taglib.html.BaseFieldTag#doStartTag()
     */
    public int doStartTag() throws JspException {
        Object value = findAncestorWithClass(this, TabSetTag.class);
        if (value == null) {
            throw new JspException("TabHeadingsTag must be contained in a TabSetTag");
        }
        TabModel model = ((TabSetTag)value).getModel();
        String bundle = ((TabSetTag)value).getBundle();
        String locale = ((TabSetTag)value).getLocale();
        String selectedTab = model.getSelectedTab();
View Full Code Here

TOP

Related Classes of javax.servlet.jsp.JspException

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.