55994
|
1 |
package javax.management.remote.rest.test.data;
|
|
2 |
|
|
3 |
/*
|
|
4 |
* QueueSample.java - Java type representing a snapshot of a given queue.
|
|
5 |
* It bundles together the instant time the snapshot was taken, the queue
|
|
6 |
* size and the queue head.
|
|
7 |
*/
|
|
8 |
|
|
9 |
|
|
10 |
|
|
11 |
import java.beans.ConstructorProperties;
|
|
12 |
import java.util.Date;
|
|
13 |
|
|
14 |
public class QueueSample {
|
|
15 |
|
|
16 |
private final Date date;
|
|
17 |
private final int size;
|
|
18 |
private final String head;
|
|
19 |
|
|
20 |
@ConstructorProperties({"date", "size", "head"})
|
|
21 |
public QueueSample(Date date, int size, String head) {
|
|
22 |
this.date = date;
|
|
23 |
this.size = size;
|
|
24 |
this.head = head;
|
|
25 |
}
|
|
26 |
|
|
27 |
public Date getDate() {
|
|
28 |
return date;
|
|
29 |
}
|
|
30 |
|
|
31 |
public int getSize() {
|
|
32 |
return size;
|
|
33 |
}
|
|
34 |
|
|
35 |
public String getHead() {
|
|
36 |
return head;
|
|
37 |
}
|
|
38 |
}
|