Commit dbc8cae1 authored by Jeremy Hylton's avatar Jeremy Hylton

More display fiddling, and remove misleading Transaction docstring.

parent 0a6ea739
...@@ -13,8 +13,8 @@ ...@@ -13,8 +13,8 @@
############################################################################## ##############################################################################
"""Transaction management """Transaction management
$Id: Transaction.py,v 1.41 2002/12/02 22:16:58 jeremy Exp $""" $Id: Transaction.py,v 1.42 2002/12/02 22:21:16 jeremy Exp $
__version__='$Revision: 1.41 $'[11:-2] """
import time, sys, struct, POSException import time, sys, struct, POSException
from struct import pack from struct import pack
...@@ -48,12 +48,11 @@ def jar_cmp(j1, j2): ...@@ -48,12 +48,11 @@ def jar_cmp(j1, j2):
return cmp(k1, k2) return cmp(k1, k2)
class Transaction: class Transaction:
'Simple transaction objects for single-threaded applications.' user = ''
user='' description = ''
description='' _connections = None
_connections=None _extension = None
_extension=None _sub = None # This is a subtrasaction flag
_sub=None # This is a subtrasaction flag
# The _non_st_objects variable is either None or a list # The _non_st_objects variable is either None or a list
# of jars that do not support subtransactions. This is used to # of jars that do not support subtransactions. This is used to
...@@ -163,10 +162,10 @@ class Transaction: ...@@ -163,10 +162,10 @@ class Transaction:
self._init() self._init()
def begin(self, info=None, subtransaction=None): def begin(self, info=None, subtransaction=None):
'''Begin a new transaction. """Begin a new transaction.
This aborts any transaction in progres. This aborts any transaction in progres.
''' """
if self._objects: if self._objects:
self.abort(subtransaction, 0) self.abort(subtransaction, 0)
if info: if info:
...@@ -175,8 +174,7 @@ class Transaction: ...@@ -175,8 +174,7 @@ class Transaction:
self.description=strip(join(info[1:],'\t')) self.description=strip(join(info[1:],'\t'))
def commit(self, subtransaction=None): def commit(self, subtransaction=None):
'Finalize the transaction' ""Finalize the transaction."""
objects = self._objects objects = self._objects
subjars = [] subjars = []
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment