'Add an interface.
intf: interface
port: port number (optional, typically OpenFlow port number)
moveIntfFn: function to move interface (optional)'

def addIntf(self, intf, port=None, moveIntfFn=moveIntf):

    if (port is None):
        port = self.newPort()
    self.intfs[port] = intf
    self.ports[intf] = port
    self.nameToIntf[intf.name] = intf
    debug('\n')
    debug(('added    intf    %s    (%d)    to    node    %s\n' % (intf, port, self.name)))
    if self.inNamespace:
        debug('moving', intf, 'into    namespace    for', self.name, '\n')
        moveIntfFn(intf.name, self)
