| 1 |
|
|
| 2 |
|
|
| 3 |
|
|
| 4 |
|
|
| 5 |
|
|
| 6 |
|
|
| 7 |
|
|
| 8 |
|
|
| 9 |
|
|
| 10 |
|
|
| 11 |
|
|
| 12 |
|
|
| 13 |
|
|
| 14 |
|
|
| 15 |
|
package org.fest.swing.edt; |
| 16 |
|
|
| 17 |
|
import java.util.concurrent.CountDownLatch; |
| 18 |
|
|
| 19 |
|
|
| 20 |
|
|
| 21 |
|
|
| 22 |
|
@author |
| 23 |
|
|
|
|
|
| 100% |
Uncovered Elements: 0 (20) |
Complexity: 8 |
Complexity Density: 0.73 |
|
| 24 |
|
abstract class GuiAction implements Runnable { |
| 25 |
|
|
| 26 |
|
private boolean executedInEDT; |
| 27 |
|
private Throwable catchedException; |
| 28 |
|
private CountDownLatch executionNotification; |
| 29 |
|
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
| 30 |
160086
|
final Throwable catchedException() { return catchedException; }... |
| 31 |
|
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
| 32 |
403
|
final void catchedException(Throwable catched) {... |
| 33 |
403
|
catchedException = catched; |
| 34 |
|
} |
| 35 |
|
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
| 36 |
3
|
final boolean wasExecutedInEDT() {... |
| 37 |
3
|
return executedInEDT; |
| 38 |
|
} |
| 39 |
|
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
| 40 |
160086
|
final void clearCatchedException() {... |
| 41 |
160086
|
catchedException = null; |
| 42 |
|
} |
| 43 |
|
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
| 44 |
151398
|
final void executionNotification(CountDownLatch c) {... |
| 45 |
151398
|
executionNotification = c; |
| 46 |
|
} |
| 47 |
|
|
|
|
|
| 100% |
Uncovered Elements: 0 (7) |
Complexity: 2 |
Complexity Density: 0.4 |
|
| 48 |
160086
|
final void notifyExecutionCompleted() {... |
| 49 |
160086
|
executedInEDT(); |
| 50 |
8688
|
if (executionNotification == null) return; |
| 51 |
151398
|
executionNotification.countDown(); |
| 52 |
151398
|
executionNotification = null; |
| 53 |
|
} |
| 54 |
|
|
|
|
|
| 100% |
Uncovered Elements: 0 (1) |
Complexity: 1 |
Complexity Density: 1 |
|
| 55 |
160086
|
private void executedInEDT() {... |
| 56 |
160086
|
executedInEDT = true; |
| 57 |
|
} |
| 58 |
|
} |