Revision 4697f1ee src/scheduler/include/HostXML.h

View differences:

src/scheduler/include/HostXML.h
47 47
        return cluster_ids;
48 48
    };
49 49

  
50
    bool is_in_cluster(const set<int> &cids) const
51
    {
52
        set<int>::const_iterator i;
53

  
54
        for (i = cids.begin(); i != cids.end(); i++)
55
        {
56
            if (cluster_ids.find(*i) != cluster_ids.end())
57
            {
58
                return true;
59
            }
60
        }
61

  
62
        return false;
63
    };
64

  
50 65
    /**
51 66
     *  Tests whether a new VM can be hosted by the host or not
52 67
     *    @param cpu needed by the VM (percentage)

Also available in: Unified diff