1 # vim: set encoding=utf-8 et sw=4 sts=4 :
3 # TODO documentation, validation
5 from pymin.seqtools import Sequence
6 from pymin.service.util import DictComposedSubHandler
8 __all__ = ('HostHandler',)
11 def __init__(self, name, ip):
14 def update(self, ip=None):
15 if ip is not None: self.ip = ip
17 return (self.name, self.ip)
19 class HostHandler(DictComposedSubHandler):
20 handler_help = u"Manage DNS hosts"
21 _comp_subhandler_cont = 'zones'
22 _comp_subhandler_attr = 'hosts'
23 _comp_subhandler_class = Host