Lines Matching refs:maxSize
51 final int maxSize;
53 private EvictingQueue(int maxSize) {
54 checkArgument(maxSize >= 0, "maxSize (%s) must >= 0", maxSize);
55 this.delegate = new ArrayDeque<E>(maxSize);
56 this.maxSize = maxSize;
60 * Creates and returns a new evicting queue that will hold up to {@code maxSize} elements.
62 * <p>When {@code maxSize} is zero, elements will be evicted immediately after being added to the
65 public static <E> EvictingQueue<E> create(int maxSize) {
66 return new EvictingQueue<E>(maxSize);
76 return maxSize - size();
101 if (maxSize == 0) {
104 if (size() == maxSize) {