- Timestamp:
- 03/01/04 11:22:30 (21 years ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
pykota/trunk/pykota/config.py
r1356 r1371 22 22 # 23 23 # $Log$ 24 # Revision 1.45 2004/03/01 10:22:30 jalet 25 # Can now extract per printer pre and post hooks from the configuration file 26 # 24 27 # Revision 1.44 2004/02/20 14:42:21 jalet 25 28 # Experimental ldapcache directive added … … 304 307 """ 305 308 validaccounters = [ "querying", "stupid", "external" ] 306 try : 307 fullaccounter = self.getPrinterOption(printername, "accounter").strip() 308 except PyKotaConfigError : 309 fullaccounter = "querying" 309 fullaccounter = self.getPrinterOption(printername, "accounter").strip() 310 310 if fullaccounter.lower().startswith("external") : 311 311 try : … … 323 323 return (fullaccounter.lower(), None) 324 324 325 def getPreHook(self, printername) : 326 """Returns the prehook command line to launch, or None if unset.""" 327 try : 328 return self.getPrinterOption(printername, "prehook").strip() 329 except PyKotaConfigError : 330 return # No command to launch in the pre-hook 331 332 def getPostHook(self, printername) : 333 """Returns the posthook command line to launch, or None if unset.""" 334 try : 335 return self.getPrinterOption(printername, "posthook").strip() 336 except PyKotaConfigError : 337 return # No command to launch in the post-hook 338 325 339 def getRequesterBackend(self, printername) : 326 340 """Returns the requester backend to use for a given printer, with its arguments."""