Package com.tech.app.functions
Class CheckThreadViolationRepaintManager
- java.lang.Object
- 
- javax.swing.RepaintManager
- 
- com.tech.app.functions.CheckThreadViolationRepaintManager
 
 
- 
 public class CheckThreadViolationRepaintManager extends javax.swing.RepaintManagerThis class is used to detect Event Dispatch Thread rule violations 
 See How to Use Threads for more infoThis is a modification of original idea of Scott Delap 
 Initial version of ThreadCheckingRepaintManager can be found here
 Easily Find Swing Threading Mistakes- Author:
- Scott Delap, Alexander Potochkin https://swinghelper.dev.java.net/
 
- 
- 
Field SummaryFields Modifier and Type Field Description private booleancompleteCheckprivate java.lang.ref.WeakReference<javax.swing.JComponent>lastComponentprivate static javax.swing.JButtontest
 - 
Constructor SummaryConstructors Constructor Description CheckThreadViolationRepaintManager()CheckThreadViolationRepaintManager(boolean completeCheck)
 - 
Method SummaryAll Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddDirtyRegion(javax.swing.JComponent component, int x, int y, int w, int h)voidaddInvalidComponent(javax.swing.JComponent component)private voidcheckThreadViolations(javax.swing.JComponent c)(package private) static voidimageUpdateTest()booleanisCompleteCheck()static voidmain(java.lang.String[] args)(package private) static voidrepaintTest()voidsetCompleteCheck(boolean completeCheck)(package private) static voidtest()protected voidviolationFound(javax.swing.JComponent c, java.lang.StackTraceElement[] stackTrace)- 
Methods inherited from class javax.swing.RepaintManageraddDirtyRegion, addDirtyRegion, currentManager, currentManager, getDirtyRegion, getDoubleBufferMaximumSize, getOffscreenBuffer, getVolatileOffscreenBuffer, isCompletelyDirty, isDoubleBufferingEnabled, markCompletelyClean, markCompletelyDirty, paintDirtyRegions, removeInvalidComponent, setCurrentManager, setDoubleBufferingEnabled, setDoubleBufferMaximumSize, toString, validateInvalidComponents
 
- 
 
- 
- 
- 
Method Detail- 
isCompleteCheckpublic boolean isCompleteCheck() 
 - 
setCompleteCheckpublic void setCompleteCheck(boolean completeCheck) 
 - 
addInvalidComponentpublic void addInvalidComponent(javax.swing.JComponent component) - Overrides:
- addInvalidComponentin class- javax.swing.RepaintManager
 
 - 
addDirtyRegionpublic void addDirtyRegion(javax.swing.JComponent component, int x, int y, int w, int h)- Overrides:
- addDirtyRegionin class- javax.swing.RepaintManager
 
 - 
checkThreadViolationsprivate void checkThreadViolations(javax.swing.JComponent c) 
 - 
violationFoundprotected void violationFound(javax.swing.JComponent c, java.lang.StackTraceElement[] stackTrace)
 - 
mainpublic static void main(java.lang.String[] args) throws java.lang.Exception- Throws:
- java.lang.Exception
 
 - 
teststatic void test() 
 - 
imageUpdateTeststatic void imageUpdateTest() 
 - 
repaintTeststatic void repaintTest() 
 
- 
 
-