resgridletlist.java

来自「一个非常著名的网格模拟器,能够运行网格调度算法!」· Java 代码 · 共 56 行

JAVA
56
字号
/* * Title:        GridSim Toolkit * Description:  GridSim (Grid Simulation) Toolkit for Modeling and Simulation *               of Parallel and Distributed Systems such as Clusters and Grids * Licence:      GPL - http://www.gnu.org/copyleft/gpl.html * * $Id: ResGridletList.java,v 1.10 2004/11/01 02:52:36 anthony Exp $ */package gridsim;import java.util.LinkedList;/** * GridSim ResGridletList maintains a linked-list of Gridlet * * @author       Manzur Murshed and Rajkumar Buyya * @since        GridSim Toolkit 1.0 * @invariant $none */public class ResGridletList extends LinkedList{    /**     * Allocates a new ResGridletList object     * @pre $none     * @post $none     */    public ResGridletList() {        super();    }    /**     * Move a ResGridlet object from this linked-list into a specified one     * @param obj a ResGridlet object to be moved     * @param list a ResGridletList object to store the new ResGridlet object     * @return <b>true</b> if the moving operation successful,     *         otherwise return <b>false</b>     * @pre obj != null     * @pre list != null     * @post $result == true || $result == false     */    public boolean move(ResGridlet obj, ResGridletList list)    {        boolean success = false;        if (super.remove(obj) == true)        {            list.add(obj);            success = true;        }        return success;    }} // end class

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?