def __init__(self, hostname, echo=True, login_type=VirtualDevice.LOGIN_TYPE_BOTH, strict=True, banner=None): thebanner = iosbanner % (hostname, hostname, hostname) VirtualDevice.__init__(self, hostname, echo=echo, login_type=login_type, strict=strict, banner=banner or thebanner) self.user_prompt = 'Username: '******'Password: '******'#' for command, handler in commands: self.add_command(command, handler)
def __init__(self, hostname, echo = True, login_type = VirtualDevice.LOGIN_TYPE_BOTH, strict = True, banner = None): thebanner = iosbanner % (hostname, hostname, hostname) VirtualDevice.__init__(self, hostname, echo = echo, login_type = login_type, strict = strict, banner = banner or thebanner) self.user_prompt = 'Username: '******'Password: '******'#' for command, handler in commands: self.add_command(command, handler)