当前位置: 首页>>代码示例>>Java>>正文


Java Cloudlet.getCloudletStatus方法代码示例

本文整理汇总了Java中org.cloudbus.cloudsim.Cloudlet.getCloudletStatus方法的典型用法代码示例。如果您正苦于以下问题:Java Cloudlet.getCloudletStatus方法的具体用法?Java Cloudlet.getCloudletStatus怎么用?Java Cloudlet.getCloudletStatus使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.cloudbus.cloudsim.Cloudlet的用法示例。


在下文中一共展示了Cloudlet.getCloudletStatus方法的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: printCloudlet

import org.cloudbus.cloudsim.Cloudlet; //导入方法依赖的package包/类
private static void printCloudlet(Cloudlet cloudlet) {
	Log.print(String.format(fInt, cloudlet.getCloudletId()));

	if (cloudlet.getCloudletStatus() == Cloudlet.SUCCESS) {
		Log.print(String.format(fString, "SUCCESS"));
		Log.print(String.format(fInt, cloudlet.getResourceId()));
		Log.print(String.format(fInt, cloudlet.getVmId()));
		Log.print(String.format(fInt, cloudlet.getCloudletLength()));
		Log.print(String.format(fFloat, cloudlet.getActualCPUTime()));
		Log.print(String.format(fFloat, cloudlet.getExecStartTime()));
		Log.print(String.format(fFloat, cloudlet.getFinishTime()));
		Log.print("\n");
	}
	else {
		Log.printLine("FAILED");
	}
}
 
开发者ID:gmartinezramirez,项目名称:Fog-Computing-Mobile-Architecture,代码行数:18,代码来源:LogPrinter.java

示例2: printCloudlet

import org.cloudbus.cloudsim.Cloudlet; //导入方法依赖的package包/类
private void printCloudlet(Cloudlet cloudlet) {
	String content = String.format(fInt, cloudlet.getCloudletId());

	if (cloudlet.getCloudletStatus() == Cloudlet.SUCCESS) {
		content = content +
				  String.format(fString, "SUCCESS") +
				  String.format(fInt, cloudlet.getResourceId()) +
				  String.format(fInt, cloudlet.getVmId()) +
				  String.format(fInt, cloudlet.getCloudletLength()) +
				  String.format(fFloat, cloudlet.getActualCPUTime()) +
				  String.format(fFloat, cloudlet.getExecStartTime()) +
				  String.format(fFloat, cloudlet.getFinishTime());
	}
	else {
		content += "FAILED";
	}
	append(content);
}
 
开发者ID:gmartinezramirez,项目名称:Fog-Computing-Mobile-Architecture,代码行数:19,代码来源:GraphicSDNExample.java

示例3: printCloudletList

import org.cloudbus.cloudsim.Cloudlet; //导入方法依赖的package包/类
/**
 * Prints the Cloudlet objects
 * @param list  list of Cloudlets
 */
private static void printCloudletList(List<Cloudlet> list) {
	int size = list.size();
	Cloudlet cloudlet;

	String indent = "    ";
	Log.printLine();
	Log.printLine("========== OUTPUT ==========");
	Log.printLine("Cloudlet ID" + indent + "STATUS" + indent +
			"Data center ID" + indent + "VM ID" + indent + "Time" + indent + "Start Time" + indent + "Finish Time");

	DecimalFormat dft = new DecimalFormat("###.##");
	for (int i = 0; i < size; i++) {
		cloudlet = list.get(i);
		Log.print(indent + cloudlet.getCloudletId() + indent + indent);

		if (cloudlet.getCloudletStatus() == Cloudlet.SUCCESS){
			Log.print("SUCCESS");

			Log.printLine( indent + indent + cloudlet.getResourceId() + indent + indent + indent + cloudlet.getVmId() +
					indent + indent + dft.format(cloudlet.getActualCPUTime()) + indent + indent + dft.format(cloudlet.getExecStartTime())+
					indent + indent + dft.format(cloudlet.getFinishTime()));
		}
	}

}
 
开发者ID:marcbux,项目名称:dynamiccloudsim,代码行数:30,代码来源:CloudSimExample4.java

示例4: printCloudletList

import org.cloudbus.cloudsim.Cloudlet; //导入方法依赖的package包/类
/**
 * Prints the Cloudlet objects
 * @param list  list of Cloudlets
 */
private static void printCloudletList(List<Cloudlet> list) {
	int size = list.size();
	Cloudlet cloudlet;

	String indent = "    ";
	Log.printLine();
	Log.printLine("========== OUTPUT ==========");
	Log.printLine("Cloudlet ID" + indent + "STATUS" + indent +
			"Data center ID" + indent + "VM ID" + indent + indent + "Time" + indent + "Start Time" + indent + "Finish Time");

	DecimalFormat dft = new DecimalFormat("###.##");
	for (int i = 0; i < size; i++) {
		cloudlet = list.get(i);
		Log.print(indent + cloudlet.getCloudletId() + indent + indent);

		if (cloudlet.getCloudletStatus() == Cloudlet.SUCCESS){
			Log.print("SUCCESS");

			Log.printLine( indent + indent + cloudlet.getResourceId() + indent + indent + indent + cloudlet.getVmId() +
					indent + indent + indent + dft.format(cloudlet.getActualCPUTime()) +
					indent + indent + dft.format(cloudlet.getExecStartTime())+ indent + indent + indent + dft.format(cloudlet.getFinishTime()));
		}
	}

}
 
开发者ID:marcbux,项目名称:dynamiccloudsim,代码行数:30,代码来源:CloudSimExample6.java

示例5: printCloudletList

import org.cloudbus.cloudsim.Cloudlet; //导入方法依赖的package包/类
/**
 * Prints the Cloudlet objects
 * @param list  list of Cloudlets
 */
private static void printCloudletList(List<Cloudlet> list) {
	int size = list.size();
	Cloudlet cloudlet;

	String indent = "    ";
	Log.printLine();
	Log.printLine("========== OUTPUT ==========");
	Log.printLine("Cloudlet ID" + indent + "STATUS" + indent +
			"Data center ID" + indent + "VM ID" + indent + "Time" + indent + "Start Time" + indent + "Finish Time");

	for (int i = 0; i < size; i++) {
		cloudlet = list.get(i);
		Log.print(indent + cloudlet.getCloudletId() + indent + indent);

		if (cloudlet.getCloudletStatus() == Cloudlet.SUCCESS){
			Log.print("SUCCESS");

			DecimalFormat dft = new DecimalFormat("###.##");
			Log.printLine( indent + indent + cloudlet.getResourceId() + indent + indent + indent + cloudlet.getVmId() +
					indent + indent + dft.format(cloudlet.getActualCPUTime()) + indent + indent + dft.format(cloudlet.getExecStartTime())+
					indent + indent + dft.format(cloudlet.getFinishTime()));
		}
	}

}
 
开发者ID:Udacity2048,项目名称:CloudSimDisk,代码行数:30,代码来源:NetworkExample1.java

示例6: printCloudletList

import org.cloudbus.cloudsim.Cloudlet; //导入方法依赖的package包/类
/**
 * Prints the Cloudlet objects.
 * 
 * @param list list of Cloudlets
 */
public static void printCloudletList(List<Cloudlet> list) {
	int size = list.size();
	Cloudlet cloudlet;

	String indent = "\t";
	Log.printLine();
	Log.printLine("========== OUTPUT ==========");
	Log.printLine("Cloudlet ID" + indent + "STATUS" + indent + "Resource ID" + indent + "VM ID" + indent
			+ "Time" + indent + "Start Time" + indent + "Finish Time");

	DecimalFormat dft = new DecimalFormat("###.##");
	for (int i = 0; i < size; i++) {
		cloudlet = list.get(i);
		Log.print(indent + cloudlet.getCloudletId());

		if (cloudlet.getCloudletStatus() == Cloudlet.SUCCESS) {
			Log.printLine(indent + "SUCCESS" + indent + indent + cloudlet.getResourceId() + indent
					+ cloudlet.getVmId() + indent + dft.format(cloudlet.getActualCPUTime()) + indent
					+ dft.format(cloudlet.getExecStartTime()) + indent + indent
					+ dft.format(cloudlet.getFinishTime()));
		}
	}
}
 
开发者ID:Udacity2048,项目名称:CloudSimDisk,代码行数:29,代码来源:Helper.java

示例7: printCloudlet

import org.cloudbus.cloudsim.Cloudlet; //导入方法依赖的package包/类
private static void printCloudlet(Cloudlet cloudlet) {
	Log.print(String.format(LogPrinter.fInt, cloudlet.getCloudletId()));

	if (cloudlet.getCloudletStatus() == Cloudlet.SUCCESS) {
		Log.print(String.format(LogPrinter.fString, "SUCCESS"));
		Log.print(String.format(LogPrinter.fInt, cloudlet.getResourceId()));
		Log.print(String.format(LogPrinter.fInt, cloudlet.getVmId()));
		Log.print(String.format(LogPrinter.fInt, cloudlet.getCloudletLength()));
		Log.print(String.format(LogPrinter.fFloat, cloudlet.getActualCPUTime()));
		Log.print(String.format(LogPrinter.fFloat, cloudlet.getExecStartTime()));
		Log.print(String.format(LogPrinter.fFloat, cloudlet.getFinishTime()));
		Log.print("\n");
	}
	else {
		Log.printLine("FAILED");
	}
}
 
开发者ID:jayjmin,项目名称:cloudsimsdn,代码行数:18,代码来源:LogPrinter.java

示例8: printCloudletList

import org.cloudbus.cloudsim.Cloudlet; //导入方法依赖的package包/类
/**
 * Prints the Cloudlet objects.
 * 
 * @param list
 *            list of Cloudlets
 * @throws IOException
 */
private static void printCloudletList(List<Cloudlet> list) throws IOException {
	int size = list.size();
	Cloudlet cloudlet;
	String indent = "    ";
	Log.printLine();
	Log.printLine("========== OUTPUT ==========");
	Log.printLine("Cloudlet ID" + indent + "STATUS" + indent + "Data center ID" + indent + "VM ID"
			+ indent + "Time" + indent + "Start Time" + indent + "Finish Time");

	DecimalFormat dft = new DecimalFormat("###.##");
	for (int i = 0; i < size; i++) {
		cloudlet = list.get(i);
		Log.print(indent + cloudlet.getCloudletId() + indent + indent);

		if (cloudlet.getCloudletStatus() == Cloudlet.SUCCESS) {
			Log.print("SUCCESS");
			Log.printLine(indent + indent + cloudlet.getResourceId() + indent + indent + indent
					+ cloudlet.getVmId() + indent + indent + dft.format(cloudlet.getActualCPUTime())
					+ indent + indent + dft.format(cloudlet.getExecStartTime()) + indent + indent
					+ dft.format(cloudlet.getFinishTime()));
		}
	}

}
 
开发者ID:demiaowu,项目名称:annotation-of-cloudsim3.0.3,代码行数:32,代码来源:TestExample.java

示例9: printCloudletList

import org.cloudbus.cloudsim.Cloudlet; //导入方法依赖的package包/类
/**
 * Prints the Cloudlet objects.
 *
 * @param list list of Cloudlets
 */
private static void printCloudletList(List<Cloudlet> list) {
	int size = list.size();
	Cloudlet cloudlet;

	String indent = "    ";
	Log.printLine();
	Log.printLine("========== OUTPUT ==========");
	Log.printLine("Cloudlet ID" + indent + "STATUS" + indent
			+ "Data center ID" + indent + "VM ID" + indent + "Time" + indent
			+ "Start Time" + indent + "Finish Time");

	DecimalFormat dft = new DecimalFormat("###.##");
	for (int i = 0; i < size; i++) {
		cloudlet = list.get(i);
		Log.print(indent + cloudlet.getCloudletId() + indent + indent);

		if (cloudlet.getCloudletStatus() == Cloudlet.SUCCESS) {
			Log.print("SUCCESS");

			Log.printLine(indent + indent + cloudlet.getResourceId()
					+ indent + indent + indent + cloudlet.getVmId()
					+ indent + indent
					+ dft.format(cloudlet.getActualCPUTime()) + indent
					+ indent + dft.format(cloudlet.getExecStartTime())
					+ indent + indent
					+ dft.format(cloudlet.getFinishTime()));
		}
	}
}
 
开发者ID:demiaowu,项目名称:annotation-of-cloudsim3.0.3,代码行数:35,代码来源:CloudSimExample1.java


注:本文中的org.cloudbus.cloudsim.Cloudlet.getCloudletStatus方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。