X-Git-Url: https://git.llucax.com/software/pymin.git/blobdiff_plain/d678eca2d9738772ed0a0b82db1792dac6730393..a3f004d7fa6113a18c0413dc37b726edbd0ebe95:/pymin/services/proxy/__init__.py?ds=inline diff --git a/pymin/services/proxy/__init__.py b/pymin/services/proxy/__init__.py index 5e8460e..2740cc8 100644 --- a/pymin/services/proxy/__init__.py +++ b/pymin/services/proxy/__init__.py @@ -21,13 +21,7 @@ class Error(HandlerError): message - A descriptive error message. """ - - def __init__(self, message): - r"Initialize the Error object. See class documentation for more info." - self.message = message - - def __str__(self): - return self.message + pass class HostError(Error, KeyError): r""" @@ -38,7 +32,7 @@ class HostError(Error, KeyError): def __init__(self, hostname): r"Initialize the object. See class documentation for more info." - self.message = 'Host error: "%s"' % hostname + self.message = u'Host error: "%s"' % hostname class HostAlreadyExistsError(HostError): r""" @@ -49,7 +43,7 @@ class HostAlreadyExistsError(HostError): def __init__(self, hostname): r"Initialize the object. See class documentation for more info." - self.message = 'Host already exists: "%s"' % hostname + self.message = u'Host already exists: "%s"' % hostname class HostNotFoundError(HostError): r""" @@ -61,7 +55,7 @@ class HostNotFoundError(HostError): def __init__(self, hostname): r"Initialize the object. See class documentation for more info." - self.message = 'Host not found: "%s"' % hostname + self.message = u'Host not found: "%s"' % hostname class Host(Sequence): @@ -74,6 +68,8 @@ class Host(Sequence): class HostHandler(Handler): + handler_help = u"Manage proxy hosts" + def __init__(self, hosts): self.hosts = hosts @@ -116,6 +112,8 @@ class UserHandler(Handler): class ProxyHandler(Restorable, ConfigWriter, InitdHandler, TransactionalHandler, ParametersHandler): + handler_help = u"Manage proxy service" + _initd_name = 'squid' _persistent_attrs = ('params', 'hosts', 'users')