public abstract class TransactionTagSupport
extends jakarta.servlet.jsp.tagext.TagSupport
implements jakarta.servlet.jsp.tagext.TryCatchFinally
Tag handler for <Transaction> in JSTL.
Modifier and Type | Field and Description |
---|---|
protected boolean |
dataSourceSpecified |
protected Object |
rawDataSource |
Constructor and Description |
---|
TransactionTagSupport() |
Modifier and Type | Method and Description |
---|---|
void |
doCatch(Throwable t)
Rollbacks the transaction and rethrows the Throwable.
|
int |
doEndTag()
Commits the transaction.
|
void |
doFinally()
Restores the
Connection to its initial state and
closes it. |
int |
doStartTag()
Prepares for execution by setting the initial state, such as
getting the
Connection and preparing it for
the transaction. |
Connection |
getSharedConnection()
Called by nested parameter elements to get a reference to
the Connection.
|
void |
release() |
void |
setIsolation(String iso)
Setter method for the transaction isolation level.
|
protected Object rawDataSource
protected boolean dataSourceSpecified
public int doStartTag() throws jakarta.servlet.jsp.JspException
Connection
and preparing it for
the transaction.doStartTag
in interface jakarta.servlet.jsp.tagext.Tag
doStartTag
in class jakarta.servlet.jsp.tagext.TagSupport
jakarta.servlet.jsp.JspException
public int doEndTag() throws jakarta.servlet.jsp.JspException
doEndTag
in interface jakarta.servlet.jsp.tagext.Tag
doEndTag
in class jakarta.servlet.jsp.tagext.TagSupport
jakarta.servlet.jsp.JspException
public void doCatch(Throwable t) throws Throwable
doCatch
in interface jakarta.servlet.jsp.tagext.TryCatchFinally
Throwable
public void doFinally()
Connection
to its initial state and
closes it.doFinally
in interface jakarta.servlet.jsp.tagext.TryCatchFinally
public void release()
release
in interface jakarta.servlet.jsp.tagext.Tag
release
in class jakarta.servlet.jsp.tagext.TagSupport
public void setIsolation(String iso) throws jakarta.servlet.jsp.JspTagException
jakarta.servlet.jsp.JspTagException
public Connection getSharedConnection()
Copyright © 2019,2020 Eclipse Foundation. All rights reserved.