jpaul.DataStructs.WorkList Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jpaul Show documentation
Show all versions of jpaul Show documentation
This library was originally developed by people listed at http://jpaul.sourceforge.net.
The newest version!
// WorkList.java, created Tue Feb 22 09:47:07 2005 by salcianu
// Copyright (C) 2003 Alexandru Salcianu
// Licensed under the Modified BSD Licence; see COPYING for details.
package jpaul.DataStructs;
import java.io.Serializable;
/**
* WorkList
is a WorkSet
with FIFO order.
* Good for algorithms that work on levels. The
* add
/extract
operations have O(1)
* complexity.
*
* @author Alexandru Salcianu - [email protected]
* @version $Id: WorkList.java,v 1.7 2006/03/14 02:29:31 salcianu Exp $ */
public class WorkList extends WorkListAbstr implements Serializable {
private static final long serialVersionUID = -260214511508356742L;
/** Overrides the abstract method {@link
jpaul.DataStructs.WorkSetAbstr#addToOrder}. Add
elem
at the tail of the list, to implement FIFO
order. */
protected void addToOrder(T elem) {
list.addLast(elem);
}
}