'Remove a server. Returns None if server interval is not empty.'

def RemoveServer(self, removed_server):

    interval = removed_server.Interval()
    if (interval.start != interval.end):
        return None
    newserverlist = []
    for serv in self.servers:
        if (serv == removed_server):
            continue
        if (serv.Index() > removed_server.Index()):
            serv.SetIndex((serv.Index() - 1))
        newserverlist.append(serv.GetInfo())
    self.mapping.servers = newserverlist
    self.mapping.num_servers -= 1
    self.servers.pop(removed_server.Index())
    self.DeregisterServer(removed_server)
    removed_server.Remove()
    return removed_server
