类 GraphicCollection
- java.lang.Object
-
- org.meteoinfo.geometry.graphic.Artist
-
- org.meteoinfo.geometry.graphic.Graphic
-
- org.meteoinfo.geometry.graphic.GraphicCollection
-
- 所有已实现的接口:
Iterator
- 直接已知子类:
GraphicCollection3D,Line2DGraphicCollection,Point2DGraphicCollection,PolygonGraphicCollection
public class GraphicCollection extends Graphic implements Iterator
- 作者:
- Yaqiang Wang
-
-
字段概要
字段 修饰符和类型 字段 说明 protected booleanavoidCollisionprotected Extentextentprotected List<? extends Graphic>graphicsprotected intindexprotected List<Graphic>labelPointsprotected LabelSetlabelSetprotected ColorBreaklegendBreakprotected LegendSchemelegendSchemeprotected booleansingleLegend
-
构造器概要
构造器 构造器 说明 GraphicCollection()Constructor
-
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 voidadd(int index, Graphic aGraphic)Inset a graphicbooleanadd(Graphic aGraphic)Add a graphicvoidaddAll(List<Graphic> gs)Add allvoidaddLabel(Graphic aLP)Add label pointvoidaddLabels()Add labelsprotected voidaddLabelsByColor()Add labelsvoidaddLabelsContourDynamic(Extent sExtent)Add labels of contour layer dynamiclyvoidclear()Clear graphicsGraphicCollectionclip(List<PolygonShape> clipPolys)Clipbooleancontains(Graphic g)Contains or notGraphicget(int idx)Get a graphic by indexfloatgetArrowZoom()Get arrow zoomExtentgetExtent()Get extentGraphicgetGraphicN(int idx)Get Graphic by indexList<? extends Graphic>getGraphics()Get graphic listGraphicgetLabel(String text)Get a label by textList<Graphic>getLabelPoints()Get label pointsLabelSetgetLabelSet()Get label setColorBreakgetLegend()Get legendColorBreakgetLegendBreak()Get legend breakList<ColorBreak>getLegends()Get legend listLegendSchemegetLegendScheme()Get legend schemeintgetNumGraphics()Get graphics numberShapegetShape()Get shapeShapegetShape(int index)Get shape by indexList<? extends Shape>getShapes()Get shapesShapeTypesgetShapeType()Get shape typebooleanhasNext()intindexOf(Graphic g)Index ofbooleanis3D()Get is 3D or notbooleanisAvoidCollision()Return avoid collision or notbooleanisCollection()Get if is GraphicCollectionbooleanisEmpty()Get is empty or notbooleanisSingleLegend()Get is single legend or notvoidjoin(Graphic graphic)Join this graphics with other graphicsvoidmoveLabel(String text, float x, float y)Move labelvoidmoveLabel(Graphic lb, float x, float y)Move labelObjectnext()Graphicremove(int index)Remove a graphic by indexbooleanremove(Graphic aGraphic)Remove a graphicvoidremoveAll(List<Graphic> gs)Remove allvoidremoveLabels()Remove all labelsGraphicCollectionselectGraphics(Extent aExtent)Select graphics by an extentvoidsetAvoidCollision(boolean value)Set avoid collision or notvoidsetExtent(Extent value)Set extentvoidsetGraphicN(int idx, Graphic graphic)Set a graphicvoidsetGraphics(List<Graphic> value)Set graphic listvoidsetLabelPoints(List<Graphic> lps)Set label pointsvoidsetLabelSet(LabelSet ls)Set label setvoidsetLegendBreak(ColorBreak value)Set legend breakvoidsetLegendScheme(LegendScheme value)Set legend schemevoidsetSingleLegend(boolean value)Set is single legend or notintsize()Get graphic list sizevoidupdateExtent()Update extentGraphicCollectionxShift(double xs)X coordinate shiftGraphicCollectionxShiftCopy(double xs)X coordinate shift as a new GraphicCollection object-
从类继承的方法 org.meteoinfo.geometry.graphic.Graphic
addLegend, addShape, doTransform, exportToXML, getClipGraphic, getClipPath, getHandle, getResizeAbility, getTransform, importFromXML, isClip, loadLegend, loadShape, setClipGraphic, setClipPath, setClipPath, setHandle, setLegend, setShape, setTransform, verticeAddUpdate, verticeMoveUpdate, verticeRemoveUpdate
-
从类继承的方法 org.meteoinfo.geometry.graphic.Artist
isAntiAlias, isVisible, setAntiAlias, setVisible
-
从类继承的方法 java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
从接口继承的方法 java.util.Iterator
forEachRemaining, remove
-
-
-
-
字段详细资料
-
extent
protected Extent extent
-
singleLegend
protected boolean singleLegend
-
index
protected int index
-
labelSet
protected LabelSet labelSet
-
legendScheme
protected LegendScheme legendScheme
-
legendBreak
protected ColorBreak legendBreak
-
avoidCollision
protected boolean avoidCollision
-
-
方法详细资料
-
getShape
public Shape getShape(int index)
Get shape by index- 参数:
index- The index- 返回:
- Shape
-
setExtent
public void setExtent(Extent value)
Set extent
-
isSingleLegend
public boolean isSingleLegend()
Get is single legend or not- 覆盖:
isSingleLegend在类中Graphic- 返回:
- Boolean
-
setSingleLegend
public void setSingleLegend(boolean value)
Set is single legend or not- 参数:
value- Boolean
-
getLabelSet
public LabelSet getLabelSet()
Get label set- 返回:
- Label set
-
setLabelSet
public void setLabelSet(LabelSet ls)
Set label set- 参数:
ls- Label set
-
setLabelPoints
public void setLabelPoints(List<Graphic> lps)
Set label points- 参数:
lps- The label points
-
getLegendScheme
public LegendScheme getLegendScheme()
Get legend scheme- 返回:
- Legend scheme
-
setLegendScheme
public void setLegendScheme(LegendScheme value)
Set legend scheme- 参数:
value- Legend scheme
-
getLegendBreak
public ColorBreak getLegendBreak()
Get legend break- 返回:
- Legend break
-
setLegendBreak
public void setLegendBreak(ColorBreak value)
Set legend break- 参数:
value- Legend break
-
is3D
public boolean is3D()
Get is 3D or not- 返回:
- Boolean
-
isCollection
public boolean isCollection()
Get if is GraphicCollection- 覆盖:
isCollection在类中Graphic- 返回:
- Boolean
-
isAvoidCollision
public boolean isAvoidCollision()
Return avoid collision or not- 返回:
- Avoid collision or not
-
setAvoidCollision
public void setAvoidCollision(boolean value)
Set avoid collision or not- 参数:
value- Avoid collision or not
-
updateExtent
public void updateExtent()
Update extent
-
add
public boolean add(Graphic aGraphic)
Add a graphic- 参数:
aGraphic- The graphic- 返回:
- Boolean
-
add
public void add(int index, Graphic aGraphic)Inset a graphic- 参数:
index- IndexaGraphic- The graphic
-
get
public Graphic get(int idx)
Get a graphic by index- 参数:
idx- Index- 返回:
- Graphic
-
indexOf
public int indexOf(Graphic g)
Index of- 参数:
g- Graphic- 返回:
- Index
-
contains
public boolean contains(Graphic g)
Contains or not- 参数:
g- Graphic- 返回:
- Boolean
-
size
public int size()
Get graphic list size- 返回:
- Graphic list size
-
isEmpty
public boolean isEmpty()
Get is empty or not- 返回:
- Boolean
-
getNumGraphics
public int getNumGraphics()
Get graphics number- 覆盖:
getNumGraphics在类中Graphic- 返回:
- 1
-
getGraphicN
public Graphic getGraphicN(int idx)
Get Graphic by index- 覆盖:
getGraphicN在类中Graphic- 参数:
idx- Index- 返回:
- Graphic
-
setGraphicN
public void setGraphicN(int idx, Graphic graphic)Set a graphic- 参数:
idx- The indexgraphic- The graphic
-
remove
public boolean remove(Graphic aGraphic)
Remove a graphic- 参数:
aGraphic- The graphic- 返回:
- Boolean
-
remove
public Graphic remove(int index)
Remove a graphic by index- 参数:
index- The index- 返回:
- The removed graphic
-
clear
public void clear()
Clear graphics
-
join
public void join(Graphic graphic)
Join this graphics with other graphics- 参数:
graphic- Other graphics
-
getLegend
public ColorBreak getLegend()
Get legend
-
getLegends
public List<ColorBreak> getLegends()
Get legend list- 返回:
- Legend list
-
selectGraphics
public GraphicCollection selectGraphics(Extent aExtent)
Select graphics by an extent- 参数:
aExtent- The extent- 返回:
- Selected graphics
-
addLabels
public void addLabels()
Add labels
-
getShapeType
public ShapeTypes getShapeType()
Get shape type- 覆盖:
getShapeType在类中Graphic- 返回:
- Shape type
-
addLabelsByColor
protected void addLabelsByColor()
Add labels
-
addLabel
public void addLabel(Graphic aLP)
Add label point- 参数:
aLP- Label point
-
addLabelsContourDynamic
public void addLabelsContourDynamic(Extent sExtent)
Add labels of contour layer dynamicly- 参数:
sExtent- View extent of MapView
-
moveLabel
public void moveLabel(String text, float x, float y)
Move label- 参数:
text- Label textx- Xy- Y
-
moveLabel
public void moveLabel(Graphic lb, float x, float y)
Move label- 参数:
lb- Labelx- Xy- Y
-
removeLabels
public void removeLabels()
Remove all labels
-
getArrowZoom
public float getArrowZoom()
Get arrow zoom- 返回:
- Arrow zoom
-
clip
public GraphicCollection clip(List<PolygonShape> clipPolys)
Clip- 参数:
clipPolys- Clipping polygons- 返回:
- Clipped graphics
-
xShift
public GraphicCollection xShift(double xs)
X coordinate shift- 参数:
xs- X shift value
-
xShiftCopy
public GraphicCollection xShiftCopy(double xs)
X coordinate shift as a new GraphicCollection object- 参数:
xs- X shift value
-
-