Changeset 980 for pykota/trunk/pykota/accounter.py
- Timestamp:
- 04/30/03 21:53:58 (21 years ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
pykota/trunk/pykota/accounter.py
r976 r980 21 21 # 22 22 # $Log$ 23 # Revision 1.3 2003/04/30 19:53:58 jalet 24 # 1.05 25 # 23 26 # Revision 1.2 2003/04/30 13:36:40 jalet 24 27 # Stupid accounting method was added. … … 43 46 class AccounterBase : 44 47 """A class to account print usage by querying printers.""" 45 def __init__(self, kotafilter ) :48 def __init__(self, kotafilter, arguments) : 46 49 """Sets instance vars depending on the current printer.""" 47 50 self.filter = kotafilter 51 self.arguments = arguments 48 52 49 53 def filterInput(self, inputfile) : … … 71 75 def openAccounter(kotafilter) : 72 76 """Returns a connection handle to the appropriate accounter.""" 73 backend= kotafilter.config.getAccounterBackend(kotafilter.printername)77 (backend, args) = kotafilter.config.getAccounterBackend(kotafilter.printername) 74 78 try : 75 79 if not backend.isalpha() : … … 80 84 raise PyKotaAccounterError, _("Unsupported accounter backend %s") % backend 81 85 else : 82 return getattr(accounterbackend, "Accounter")(kotafilter )86 return getattr(accounterbackend, "Accounter")(kotafilter, args)