<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
</head>
<body text="#000000" bgcolor="#ffffff">
Another option is for the transaction utility class to provide the
convenience methods without extending UserTransaction, i.e like this:<br>
<br>
public boolean isActive(UserTransaction transaction) {<br>
  return transaction.getStatus() == STATUS.ACTIVE;<br>
}<br>
<br>
<br>
On 15/04/10 04:21, Dan Allen wrote:
<blockquote
 cite="mid:v2m19758da1004141121yc6442fe8ifd1ac334f595f63c@mail.gmail.com"
 type="cite">
  <div class="gmail_quote">On Wed, Apr 14, 2010 at 9:13 AM, Pete Muir <span
 dir="ltr">&lt;<a moz-do-not-send="true" href="mailto:pmuir@redhat.com">pmuir@redhat.com</a>&gt;</span>
wrote:<br>
  <blockquote class="gmail_quote"
 style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">I'm
with Emmanuel here.<br>
    <br>
All of this is addressable through an Transactions utiltiy class.<br>
    <div>
    <div class="h5"><br>
    </div>
    </div>
  </blockquote>
  <div>Let me ask for two clarifications that will help me understand
the counter argument.</div>
  <div><br>
  </div>
  <div>1. If this transaction wrapper extends UserTransaction, is that
worse/different than having a utility class? You can always inject the
native type, or inject the wrapper for the extra convenient status
methods.</div>
  <div>2. The transaction wrapper allows us reuse the UserTransaction
API to address JTA, resource-local and potentially spring transaction
APIs as one. The client then doesn't concern itself with which
transaction API is being used under the covers, but everyone "speaks"
JTA UserTransaction. How do we do that with just a utility class?</div>
  <div><br>
  </div>
  <div>-Dan</div>
  <div> </div>
  </div>
-- <br>
Dan Allen<br>
Senior Software Engineer, Red Hat | Author of Seam in Action<br>
Registered Linux User #231597<br>
  <br>
  <a moz-do-not-send="true" href="http://mojavelinux.com">http://mojavelinux.com</a><br>
  <a moz-do-not-send="true" href="http://mojavelinux.com/seaminaction">http://mojavelinux.com/seaminaction</a><br>
  <a moz-do-not-send="true"
 href="http://www.google.com/profiles/dan.j.allen">http://www.google.com/profiles/dan.j.allen</a><br>
  <pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
seam-dev mailing list
<a class="moz-txt-link-abbreviated" href="mailto:seam-dev@lists.jboss.org">seam-dev@lists.jboss.org</a>
<a class="moz-txt-link-freetext" href="https://lists.jboss.org/mailman/listinfo/seam-dev">https://lists.jboss.org/mailman/listinfo/seam-dev</a>
  </pre>
</blockquote>
<br>
</body>
</html>