def __init__(self, filename=None):
        self.filename = None
        if filename:
            self.load(filename)
def __init__(self):
        super(TransactionStates, self).__init__()
        self._states = defaultdict(TransactionState)