org.jplot2d.element.impl
Class ImageGraphImpl
- java.lang.Object
-
- org.jplot2d.element.impl.ElementImpl
-
- org.jplot2d.element.impl.ComponentImpl
-
- org.jplot2d.element.impl.GraphImpl
-
- org.jplot2d.element.impl.ImageGraphImpl
-
- All Implemented Interfaces:
- Element, Graph, ImageGraph, ComponentEx, ElementEx, GraphEx, ImageGraphEx, IntermediateCacheEx, PComponent
public class ImageGraphImpl extends GraphImpl implements ImageGraphEx, IntermediateCacheEx
-
-
Constructor Summary
Constructors Constructor and Description ImageGraphImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description voidcopyFrom(ElementEx src)Copies all properties from given src to this element.ComponentExcopyStructure(java.util.Map<ElementEx,ElementEx> orig2copyMap)Create a structural copy of this element and put them into orig2copyMap.java.lang.ObjectcreateCacheHolder()Create a cache holder to keep intermediate calculation result.voiddraw(java.awt.Graphics2D graphics)Draw this component only.SingleBandImageDatagetData()Returns the graph data that this graph will draw.java.lang.StringgetId()Returns the id string of this elementImageMappingExgetMapping()Returns the mapping of this image.voidmappingChanged()Notify this graph that the mapping limits or LUT changed.voidsetData(SingleBandImageData data)voidsetMapping(ImageMapping mapping)voidthisEffectiveColorChanged()Called when setColor() or parentEffectiveColorChanged() change the effective color of this component.-
Methods inherited from class org.jplot2d.element.impl.GraphImpl
getInvokeStepFormParent, getLocation, getParent, getSize, setLocation, thisEffectiveFontChanged
-
Methods inherited from class org.jplot2d.element.impl.ComponentImpl
addPropertyChangeListener, canContribute, getBounds, getColor, getEffectiveColor, getEffectiveFont, getEffectiveFontName, getEffectiveFontSize, getEffectiveFontStyle, getFontName, getFontScale, getFontSize, getFontStyle, getMooringMap, getPaperTransform, getSelectableBounds, getZOrder, isCacheable, isMovable, isRedrawNeeded, isSelectable, isVisible, parentEffectiveColorChanged, parentEffectiveFontChanged, removePropertyChangeListener, setCacheable, setColor, setFont, setFontName, setFontScale, setFontSize, setFontStyle, setMovable, setRedrawNeeded, setSelectable, setVisible, setZOrder
-
Methods inherited from class org.jplot2d.element.impl.ElementImpl
getEnvironment, getFullId, notify, setParent, toString
-
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.jplot2d.element.impl.ComponentEx
canContribute, getEffectiveColor, getEffectiveFontName, getEffectiveFontSize, getEffectiveFontStyle, getMooringMap, isMovable, isRedrawNeeded, parentEffectiveColorChanged, parentEffectiveFontChanged, setMovable, setRedrawNeeded, thisEffectiveFontChanged
-
Methods inherited from interface org.jplot2d.element.PComponent
getBounds, getColor, getEffectiveFont, getFontName, getFontScale, getFontSize, getFontStyle, getLocation, getPaperTransform, getSelectableBounds, getSize, getZOrder, isCacheable, isSelectable, isVisible, setCacheable, setColor, setFont, setFontName, setFontScale, setFontSize, setFontStyle, setSelectable, setVisible, setZOrder
-
Methods inherited from interface org.jplot2d.element.impl.ElementEx
getFullId, getInvokeStepFormParent, notify, setParent
-
Methods inherited from interface org.jplot2d.element.Element
getEnvironment
-
-
-
-
Method Detail
-
getId
public java.lang.String getId()
Description copied from interface:ElementReturns the id string of this element
-
getMapping
public ImageMappingEx getMapping()
Description copied from interface:ImageGraphReturns the mapping of this image.- Specified by:
getMappingin interfaceImageGraph- Specified by:
getMappingin interfaceImageGraphEx- Returns:
- the mapping of this image
-
setMapping
public void setMapping(ImageMapping mapping)
- Specified by:
setMappingin interfaceImageGraph
-
getData
public SingleBandImageData getData()
Description copied from interface:GraphReturns the graph data that this graph will draw.- Specified by:
getDatain interfaceGraph- Specified by:
getDatain interfaceImageGraph- Returns:
-
setData
public void setData(SingleBandImageData data)
- Specified by:
setDatain interfaceImageGraph
-
thisEffectiveColorChanged
public void thisEffectiveColorChanged()
Description copied from interface:ComponentExCalled when setColor() or parentEffectiveColorChanged() change the effective color of this component.- Specified by:
thisEffectiveColorChangedin interfaceComponentEx
-
mappingChanged
public void mappingChanged()
Description copied from interface:ImageGraphExNotify this graph that the mapping limits or LUT changed.- Specified by:
mappingChangedin interfaceImageGraphEx
-
createCacheHolder
public java.lang.Object createCacheHolder()
Description copied from interface:IntermediateCacheExCreate a cache holder to keep intermediate calculation result. This method is called by PlotEnvironment.commit(), before create thread-safe copy for renderers. The PlotEnvironment will keep hard reference to the returned Object. Usually the returned object is used as key of WeakHashMap.- Specified by:
createCacheHolderin interfaceIntermediateCacheEx- Returns:
- an object to that PlotEnvironment should keep reference
-
copyStructure
public ComponentEx copyStructure(java.util.Map<ElementEx,ElementEx> orig2copyMap)
Description copied from interface:ElementExCreate a structural copy of this element and put them into orig2copyMap. All properties are not copied. The parent of the copy are not set by this method.- Specified by:
copyStructurein interfaceComponentEx- Specified by:
copyStructurein interfaceElementEx- Overrides:
copyStructurein classComponentImpl- Parameters:
orig2copyMap- original element to copy map- Returns:
- the structural copy of this element
-
copyFrom
public void copyFrom(ElementEx src)
Description copied from interface:ElementExCopies all properties from given src to this element. Notice properties of sub-elements are not copied over.- Specified by:
copyFromin interfaceElementEx- Overrides:
copyFromin classComponentImpl- Parameters:
src- the src
-
draw
public void draw(java.awt.Graphics2D graphics)
Description copied from interface:ComponentExDraw this component only. All its children is not drawn.- Specified by:
drawin interfaceComponentEx- Parameters:
graphics- to the Graphics2D drawing. The transformation of this component is not applied.
-
-
DMelt 3.0 © DataMelt by jWork.ORG