程序包 weka.core
类 Queue
java.lang.Object
weka.core.Queue
- 所有已实现的接口:
Serializable
,RevisionHandler
Class representing a FIFO queue.
- 版本:
- $Revision: 1.10 $
- 作者:
- Len Trigg (trigg@cs.waikato.ac.nz)
- 另请参阅:
-
构造器概要
构造器 -
方法概要
修饰符和类型方法说明boolean
empty()
Checks if queue is empty.Returns the revision string.static void
Main method for testing this class.peek()
Gets object from the front of the queue.pop()
Pops an object from the front of the queue.Appends an object to the back of the queue.final void
Removes all objects from the queue m_Tail.m_Next.int
size()
Gets queue's size.toString()
Produces textual description of queue.
-
构造器详细资料
-
Queue
public Queue()
-
-
方法详细资料
-
removeAllElements
public final void removeAllElements()Removes all objects from the queue m_Tail.m_Next. -
push
Appends an object to the back of the queue.- 参数:
item
- the object to be appended- 返回:
- the object appended
-
pop
Pops an object from the front of the queue.- 返回:
- the object at the front of the queue
- 抛出:
RuntimeException
- if the queue is empty
-
peek
Gets object from the front of the queue.- 返回:
- the object at the front of the queue
- 抛出:
RuntimeException
- if the queue is empty
-
empty
public boolean empty()Checks if queue is empty.- 返回:
- true if queue is empty
-
size
public int size()Gets queue's size.- 返回:
- size of queue
-
toString
Produces textual description of queue. -
getRevision
Returns the revision string.- 指定者:
getRevision
在接口中RevisionHandler
- 返回:
- the revision
-
main
Main method for testing this class.- 参数:
argv
- a set of strings that are pushed on a test queue
-