def __init__(self, name, host='127.0.0.1', port=27017):
        self.name = name
        self.host = host
        self.port = port
def encode(self):
        return {"rx_sw_if_index": self._rx_index,
                "tx_sw_if_index": self._tx_index, "nh": self._nh_addr}