Class OverlayUtility
- java.lang.Object
- 
- com.inductiveautomation.factorypmi.application.components.overlay.OverlayUtility
 
- 
 public class OverlayUtility extends java.lang.ObjectClass that manages painting data quality overlays for JComponents that are QualityMonitors.
- 
- 
Nested Class SummaryNested Classes Modifier and Type Class Description static classOverlayUtility.OverlayReferencePanel
 - 
Field SummaryFields Modifier and Type Field Description static booleanFORCE_QUALITY_CHANGESet this tag before calling updateQuality to force a quality change to be fired.static java.lang.StringQUALITY_SUFFIXIf you have a property named "foo", then when its quality changes, you'll get a property change event fired for "foo"+QUALITY_SUFFIX
 - 
Constructor SummaryConstructors Constructor Description OverlayUtility()
 - 
Method SummaryAll Methods Static Methods Concrete Methods Modifier and Type Method Description static java.util.Map<java.lang.String,QualityCode>getQualities(javax.swing.JComponent comp)Return all qualities registered for the componentstatic QualityCodegetQuality(javax.swing.JComponent comp, java.lang.String propertyName)Attempts to look up the quality for an individual property.static booleanisOverlaysEnabled()static booleanisTemplateEditingActive()static voidmain(java.lang.String[] args)static voidpaintOverlay(QualityMonitor qm, java.awt.Graphics graphics)static voidpaintOverlay(javax.swing.JComponent comp, java.awt.Graphics graphics, QualityCode quality)static voidsetOverlaysEnabled(boolean overlaysEnabled)static voidsetTemplateEditingActive(boolean templateEditingActive)static voidupdateQuality(QualityMonitor qm, java.lang.String propName, QualityCode qualityCode)Iterates through a list of property qualities stored in the JComponent's client property map.
 
- 
- 
- 
Field Detail- 
QUALITY_SUFFIXpublic static final java.lang.String QUALITY_SUFFIX If you have a property named "foo", then when its quality changes, you'll get a property change event fired for "foo"+QUALITY_SUFFIX- See Also:
- Constant Field Values
 
 - 
FORCE_QUALITY_CHANGEpublic static boolean FORCE_QUALITY_CHANGE Set this tag before calling updateQuality to force a quality change to be fired.
 
- 
 - 
Method Detail- 
setOverlaysEnabledpublic static void setOverlaysEnabled(boolean overlaysEnabled) 
 - 
isOverlaysEnabledpublic static boolean isOverlaysEnabled() 
 - 
setTemplateEditingActivepublic static void setTemplateEditingActive(boolean templateEditingActive) 
 - 
isTemplateEditingActivepublic static boolean isTemplateEditingActive() 
 - 
paintOverlaypublic static void paintOverlay(QualityMonitor qm, java.awt.Graphics graphics) 
 - 
paintOverlaypublic static void paintOverlay(javax.swing.JComponent comp, java.awt.Graphics graphics, QualityCode quality)
 - 
getQualitypublic static QualityCode getQuality(javax.swing.JComponent comp, java.lang.String propertyName) Attempts to look up the quality for an individual property. If no quality is found then good quality is assumed.
 - 
getQualitiespublic static java.util.Map<java.lang.String,QualityCode> getQualities(javax.swing.JComponent comp) Return all qualities registered for the component
 - 
updateQualitypublic static void updateQuality(QualityMonitor qm, java.lang.String propName, QualityCode qualityCode) Iterates through a list of property qualities stored in the JComponent's client property map. Uses a list rather than a map b/c we'd have to iterate through the map anyhow, so its not efficient If you call this from a non-EDT thread, it will be wrapped in an invokeLater for you automatically. 
 - 
mainpublic static void main(java.lang.String[] args) 
 
- 
 
-