Home
last modified time | relevance | path

Searched refs:remainingCapacity (Results 1 – 25 of 29) sorted by relevance

12

/libcore/ojluni/src/test/java/util/concurrent/tck/
DArrayBlockingQueueTest.java119 assertEquals(capacity - size, q.remainingCapacity()); in populatedQueue()
130 assertEquals(SIZE, new ArrayBlockingQueue(SIZE).remainingCapacity()); in testConstructor1()
219 assertEquals(2, q.remainingCapacity()); in testEmptyFull()
224 assertEquals(0, q.remainingCapacity()); in testEmptyFull()
234 int spare = q.remainingCapacity(); in testRemainingCapacity()
237 assertEquals(spare + i, q.remainingCapacity()); in testRemainingCapacity()
238 assertEquals(capacity, q.size() + q.remainingCapacity()); in testRemainingCapacity()
242 assertEquals(capacity - i, q.remainingCapacity()); in testRemainingCapacity()
243 assertEquals(capacity, q.size() + q.remainingCapacity()); in testRemainingCapacity()
263 assertEquals(0, q.remainingCapacity()); in testAdd()
[all …]
DLinkedBlockingQueueTest.java96 assertEquals(0, q.remainingCapacity()); in populatedQueue()
107 assertEquals(SIZE, new LinkedBlockingQueue(SIZE).remainingCapacity()); in testConstructor1()
108 assertEquals(Integer.MAX_VALUE, new LinkedBlockingQueue().remainingCapacity()); in testConstructor1()
175 assertEquals("should have room for 2", 2, q.remainingCapacity()); in testEmptyFull()
180 assertEquals(0, q.remainingCapacity()); in testEmptyFull()
190 assertEquals(i, q.remainingCapacity()); in testRemainingCapacity()
191 assertEquals(SIZE, q.size() + q.remainingCapacity()); in testRemainingCapacity()
195 assertEquals(SIZE - i, q.remainingCapacity()); in testRemainingCapacity()
196 assertEquals(SIZE, q.size() + q.remainingCapacity()); in testRemainingCapacity()
217 assertEquals(0, q.remainingCapacity()); in testAdd()
[all …]
DLinkedBlockingDequeTest.java96 assertEquals(0, q.remainingCapacity()); in populatedDeque()
367 assertEquals(SIZE, new LinkedBlockingDeque(SIZE).remainingCapacity()); in testConstructor1()
368 assertEquals(Integer.MAX_VALUE, new LinkedBlockingDeque().remainingCapacity()); in testConstructor1()
435 assertEquals("should have room for 2", 2, q.remainingCapacity()); in testEmptyFull()
440 assertEquals(0, q.remainingCapacity()); in testEmptyFull()
450 assertEquals(i, q.remainingCapacity()); in testRemainingCapacity()
451 assertEquals(SIZE, q.size() + q.remainingCapacity()); in testRemainingCapacity()
455 assertEquals(SIZE - i, q.remainingCapacity()); in testRemainingCapacity()
456 assertEquals(SIZE, q.size() + q.remainingCapacity()); in testRemainingCapacity()
482 assertEquals(0, q.remainingCapacity()); in testPush()
[all …]
DSynchronousQueueTest.java85 assertEquals(0, q.remainingCapacity()); in testEmptyFull()
106 assertEquals(0, q.remainingCapacity()); in testAdd()
172 assertEquals(0, q.remainingCapacity()); in testBlockingPut()
198 assertEquals(0, q.remainingCapacity()); in testPutWithTake()
206 assertEquals(0, q.remainingCapacity()); in testPutWithTake()
509 assertEquals(0, q.remainingCapacity());
562 assertEquals(0, clone.remainingCapacity());
DDelayQueueTest.java154 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in populatedQueue()
164 assertEquals(Integer.MAX_VALUE, new DelayQueue().remainingCapacity()); in testConstructor1()
218 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in testEmpty()
233 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in testRemainingCapacity()
238 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in testRemainingCapacity()
535 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in testClear()
DPriorityBlockingQueueTest.java106 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in populatedQueue()
117 new PriorityBlockingQueue(SIZE).remainingCapacity()); in testConstructor1()
198 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in testEmpty()
213 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in testRemainingCapacity()
218 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in testRemainingCapacity()
DLinkedTransferQueueTest.java156 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in testRemainingCapacity()
161 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in testRemainingCapacity()
433 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in testClear()
577 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in testIteratorOrdering()
581 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in testIteratorOrdering()
1067 assertEquals(Integer.MAX_VALUE, q.remainingCapacity());
DBlockingQueueTest.java222 if (q.remainingCapacity() > 0) {
369 final int size = Math.min(q.remainingCapacity(), SIZE);
/libcore/jsr166-tests/src/test/java/jsr166/
DLinkedBlockingQueueTest.java67 assertEquals(0, q.remainingCapacity()); in populatedQueue()
77 assertEquals(SIZE, new LinkedBlockingQueue(SIZE).remainingCapacity()); in testConstructor1()
78 assertEquals(Integer.MAX_VALUE, new LinkedBlockingQueue().remainingCapacity()); in testConstructor1()
145 assertEquals("should have room for 2", 2, q.remainingCapacity()); in testEmptyFull()
150 assertEquals(0, q.remainingCapacity()); in testEmptyFull()
160 assertEquals(i, q.remainingCapacity()); in testRemainingCapacity()
161 assertEquals(SIZE, q.size() + q.remainingCapacity()); in testRemainingCapacity()
165 assertEquals(SIZE - i, q.remainingCapacity()); in testRemainingCapacity()
166 assertEquals(SIZE, q.size() + q.remainingCapacity()); in testRemainingCapacity()
187 assertEquals(0, q.remainingCapacity()); in testAdd()
[all …]
DArrayBlockingQueueTest.java66 assertEquals(0, q.remainingCapacity()); in populatedQueue()
75 assertEquals(SIZE, new ArrayBlockingQueue(SIZE).remainingCapacity()); in testConstructor1()
156 assertEquals(2, q.remainingCapacity()); in testEmptyFull()
161 assertEquals(0, q.remainingCapacity()); in testEmptyFull()
171 assertEquals(i, q.remainingCapacity()); in testRemainingCapacity()
172 assertEquals(SIZE, q.size() + q.remainingCapacity()); in testRemainingCapacity()
176 assertEquals(SIZE - i, q.remainingCapacity()); in testRemainingCapacity()
177 assertEquals(SIZE, q.size() + q.remainingCapacity()); in testRemainingCapacity()
199 assertEquals(0, q.remainingCapacity()); in testAdd()
271 assertEquals(0, q.remainingCapacity()); in testPut()
[all …]
DLinkedBlockingDequeTest.java64 assertEquals(0, q.remainingCapacity()); in populatedDeque()
333 assertEquals(SIZE, new LinkedBlockingDeque(SIZE).remainingCapacity()); in testConstructor1()
334 assertEquals(Integer.MAX_VALUE, new LinkedBlockingDeque().remainingCapacity()); in testConstructor1()
401 assertEquals("should have room for 2", 2, q.remainingCapacity()); in testEmptyFull()
406 assertEquals(0, q.remainingCapacity()); in testEmptyFull()
416 assertEquals(i, q.remainingCapacity()); in testRemainingCapacity()
417 assertEquals(SIZE, q.size() + q.remainingCapacity()); in testRemainingCapacity()
421 assertEquals(SIZE - i, q.remainingCapacity()); in testRemainingCapacity()
422 assertEquals(SIZE, q.size() + q.remainingCapacity()); in testRemainingCapacity()
448 assertEquals(0, q.remainingCapacity()); in testPush()
[all …]
DSynchronousQueueTest.java64 assertEquals(0, q.remainingCapacity()); in testEmptyFull()
85 assertEquals(0, q.remainingCapacity()); in testAdd()
151 assertEquals(0, q.remainingCapacity()); in testBlockingPut()
177 assertEquals(0, q.remainingCapacity()); in testPutWithTake()
185 assertEquals(0, q.remainingCapacity()); in testPutWithTake()
489 assertEquals(0, q.remainingCapacity());
542 assertEquals(0, clone.remainingCapacity());
DDelayQueueTest.java147 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in populatedQueue()
156 assertEquals(Integer.MAX_VALUE, new DelayQueue().remainingCapacity()); in testConstructor1()
210 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in testEmpty()
225 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in testRemainingCapacity()
230 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in testRemainingCapacity()
527 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in testClear()
DPriorityBlockingQueueTest.java77 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in populatedQueue()
87 new PriorityBlockingQueue(SIZE).remainingCapacity()); in testConstructor1()
168 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in testEmpty()
183 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in testRemainingCapacity()
188 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in testRemainingCapacity()
DLinkedTransferQueueTest.java138 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in testRemainingCapacity()
143 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in testRemainingCapacity()
415 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in testClear()
560 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in testIteratorOrdering()
564 assertEquals(Integer.MAX_VALUE, q.remainingCapacity()); in testIteratorOrdering()
1053 assertEquals(Integer.MAX_VALUE, q.remainingCapacity());
DBlockingQueueTest.java198 if (q.remainingCapacity() > 0) {
345 final int size = Math.min(q.remainingCapacity(), SIZE);
/libcore/ojluni/src/main/java/java/util/concurrent/
DBlockingQueue.java291 int remainingCapacity(); in remainingCapacity() method
DDelayQueue.java387 public int remainingCapacity() { in remainingCapacity() method in DelayQueue
DScheduledThreadPoolExecutor.java1087 public int remainingCapacity() { in remainingCapacity() method in ScheduledThreadPoolExecutor.DelayedWorkQueue
DSynchronousQueue.java946 public int remainingCapacity() { in remainingCapacity() method in SynchronousQueue
DPriorityBlockingQueue.java597 public int remainingCapacity() { in remainingCapacity() method in PriorityBlockingQueue
DLinkedBlockingQueue.java315 public int remainingCapacity() { in remainingCapacity() method in LinkedBlockingQueue
/libcore/ojluni/annotations/hiddenapi/java/util/concurrent/
DLinkedBlockingQueue.java84 public int remainingCapacity() { in remainingCapacity() method in LinkedBlockingQueue
DPriorityBlockingQueue.java132 public int remainingCapacity() { in remainingCapacity() method in PriorityBlockingQueue
DLinkedBlockingDeque.java210 public int remainingCapacity() { in remainingCapacity() method in LinkedBlockingDeque

12