Last active
December 17, 2015 01:09
-
-
Save hackerain/5525906 to your computer and use it in GitHub Desktop.
顺序分配
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public void bindCloudletsToVmsSimple(){ | |
int vmNum = vmList.size(); | |
int cloudletNum = cloudletList.size(); | |
int idx = 0; | |
for (int i=0;i<cloudletNum;i++){ | |
cloudletList.get(i).setVmId(vmList.get(idx).getId()); | |
idx = (idx+1)%vmNum; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment