org.eclipse.mat.collect

## Class QueueInt

- java.lang.Object
- - org.eclipse.mat.collect.QueueInt

    public class QueueInt
    extends Object

A simple queue of ints

Since:
  0.8

### Constructor Summary

Constructors
Constructor and Description
`QueueInt(int capacity)` Create a queue of specified initial capacity.

### Method Summary

All Methods Instance Methods Concrete Methods
`int` `get()` Retrieve the next element from the queue.
`void` `put(int x)` Add an element to the back of the queue.
`int` `size()` The number of elements available for retrieval.

### Methods inherited from class java.lang.Object

`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Constructor Detail

#### QueueInt

    public QueueInt(int capacity)

Create a queue of specified initial capacity. The queue can grow if required.

Parameters:
  `capacity` - the initial capacity

### Method Detail

#### get

    public final int get()

Retrieve the next element from the queue.

Returns:
  the next element

#### size

    public final int size()

The number of elements available for retrieval.

Returns:
  the size

#### put

    public final void put(int x)

Add an element to the back of the queue.

Parameters:
  `x` - the element to add