Package javax.servlet.jsp

Examples of javax.servlet.jsp.JspTagException


    else if (items instanceof String && delims == null)
    return new IteratedValueExpression(new IteratedExpression(expr, null), i);
    else if (items instanceof String && delims != null)
      return new CoreStringTokenValueExpression(expr, i, delims);
    else
      throw new JspTagException(L.l("unknown items value '{0}'", items));
  }
View Full Code Here


  }

  public int doStartTag() throws JspException
  {
    if (pageContext.getAttribute("caucho.jstl.sql.conn") != null)
      throw new JspTagException(L.l("nexted sql:transaction are forbidden"));

    ELContext env = pageContext.getELContext();
   
    try {
      DataSource ds;

      if (_dataSource != null)
        ds = SqlQueryTag.getDataSource(pageContext, _dataSource.evalObject(env));
      else
        ds = SqlQueryTag.getDataSource(pageContext, null);

      int isolationCode = -1;
      if (_isolation != null) {
        String isolation = _isolation.evalString(env);

        if (isolation.equals("read_committed"))
          isolationCode = Connection.TRANSACTION_READ_COMMITTED;
        else if (isolation.equals("read_uncommitted"))
          isolationCode = Connection.TRANSACTION_READ_UNCOMMITTED;
        else if (isolation.equals("repeatable_read"))
          isolationCode = Connection.TRANSACTION_REPEATABLE_READ;
        else if (isolation.equals("serializable"))
          isolationCode = Connection.TRANSACTION_SERIALIZABLE;
        else
          throw new JspTagException(L.l("unknown sql:transaction isolation ~{0}'", isolation));
      }

      _conn = ds.getConnection();

      _oldIsolation = _conn.getTransactionIsolation();
View Full Code Here

    else if (items instanceof Enumeration)
      return new EnumIterator((Enumeration) items);
    else if (items instanceof String)
      return new StringIterator((String) items);
    else
      throw new JspTagException(L.l("unknown items value `{0}'", items));
  }
View Full Code Here

    ELContext env = pageContext.getELContext();
   
    String url = _urlExpr.evalString(env);

    if (url == null || url.equals(""))
      throw new JspTagException(L.l("URL may not be null for `{0}'",
                                    _urlExpr));

    if (_query == null || _query.getLength() == 0) {
    }
    else if (url.indexOf('?') > 0)
View Full Code Here

   */
  protected void validateBegin()
    throws JspTagException
  {
    if (begin < 0)
      throw new JspTagException("Invalid loop tag, 'begin' < 0.");
  }
View Full Code Here

   */
  protected void validateEnd()
    throws JspTagException
  {
    if (this.end < 0)
      throw new JspTagException("Invalid loop tag, 'end' < 0.");
  }
View Full Code Here

   */
  protected void validateStep()
    throws JspTagException
  {
    if (step <= 0)
      throw new JspTagException("Invalid loop tag, 'step' <= 0.");
  }
View Full Code Here

        new IteratedExpression(deferredExpression, null), index);
    else if (items instanceof String)
      return new IteratedValueExpression(
        new IteratedExpression(deferredExpression, getDelims()), index);
    else
      throw new JspTagException("unknown items value '" + items + "'");
  }
View Full Code Here

            }

        } catch (final JspTagException jte) {
            throw jte;
        } catch (final IOException ioe) {
            throw new JspTagException(ioe);
        } catch (final ServletException ce) {
            throw new JspTagException(TagUtil.getRootCause(ce));
        }

        return EVAL_PAGE;
    }
View Full Code Here

            ServletRequest request, ServletResponse response)
            throws IOException, ServletException, JspTagException {
        try {
            dispatcher.forward(request, response);
        } catch (IllegalStateException ise) {
            throw new JspTagException(ise);
        }
    }
View Full Code Here

TOP

Related Classes of javax.servlet.jsp.JspTagException

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.