prefixtemplate.py
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 __author__ = "Cyril Jaquier"
00023 __version__ = "$Revision: 645 $"
00024 __date__ = "$Date: 2008-01-16 23:55:04 +0100 (Wed, 16 Jan 2008) $"
00025 __copyright__ = "Copyright (c) 2004 Cyril Jaquier"
00026 __license__ = "GPL"
00027
00028 from template import Template, Templates
00029
00030 class PrefixTemplate(Template):
00031
00032 def __init__(self):
00033 Template.__init__(self, Template.TEMPLATE_PREFIX, "<PREFIX>")
00034
00035
00036 class PrefixTemplates(Templates):
00037
00038 def __init__(self):
00039 Templates.__init__(self)
00040
00041 template = PrefixTemplate()
00042 template.setRegex("\S+ \S+\[\d+\]:")
00043 self.templates.append(template)
00044
00045 template = PrefixTemplate()
00046 template.setRegex("\[\S+\] \S+: \S+:")
00047 self.templates.append(template)
00048
00049 template = PrefixTemplate()
00050 template.setRegex("\S+ \S+:")
00051 self.templates.append(template)