code: public void close() {
          if (transactionalBranch != null) {
              XATransactionalBranch<C> branch= this.transactionalBranch;
              this.release();
              branch.getManagedConnection().close();
          }
  
      }
docs: releases and closes the associated TransactionalBranch, and releases the associated resources