Class Graphic

    • Constructor Detail

      • Graphic

        public Graphic​()
        Constructor
      • Graphic

        public Graphic​(Shape shape,
                       ColorBreak legend)
        Constructor
        Parameters:
        shape - a shape
        legend - a legend
    • Method Detail

      • getShape

        public Shape getShape​()
        Get shape
        Returns:
        Shape
      • setShape

        public void setShape​(Shape aShape)
        Set shape
        Parameters:
        aShape - a shape
      • getLegend

        public ColorBreak getLegend​()
        Get legend
        Returns:
        Legend
      • setLegend

        public void setLegend​(ColorBreak legend)
      • getResizeAbility

        public ResizeAbility getResizeAbility​()
        Get resize ability
        Returns:
        Resize ability
      • getExtent

        public Extent getExtent​()
        Get extent
        Returns:
        The extent
      • setExtent

        public void setExtent​(Extent value)
        Set extent
        Parameters:
        value - The extent
      • isSingleLegend

        public boolean isSingleLegend​()
        Get is single legend or not
        Returns:
        Boolean
      • isCollection

        public boolean isCollection​()
        Get if is GraphicCollection
        Returns:
        Boolean
      • getNumGraphics

        public int getNumGraphics​()
        Get graphics number
        Returns:
        1
      • getGraphicN

        public Graphic getGraphicN​(int idx)
        Get Graphic by index
        Parameters:
        idx - Index
        Returns:
        Graphic
      • getGraphics

        public java.util.List<Graphic> getGraphics​()
        Get graphic list
        Returns:
        Graphic list
      • verticeMoveUpdate

        public void verticeMoveUpdate​(int vIdx,
                                      double newX,
                                      double newY)
        Vertice edited update
        Parameters:
        vIdx - Vertice index
        newX - New X
        newY - New Y
      • verticeAddUpdate

        public void verticeAddUpdate​(int vIdx,
                                     PointD point)
        Vertice edited update
        Parameters:
        vIdx - Vertice index
        point - The add vertice
      • verticeRemoveUpdate

        public void verticeRemoveUpdate​(int vIdx)
        Vertice edited update
        Parameters:
        vIdx - Vertice index
      • exportToXML

        public void exportToXML​(org.w3c.dom.Document doc,
                                org.w3c.dom.Element parent)
        Export to XML document
        Parameters:
        doc - XML document
        parent - Parent XML element
      • addShape

        protected void addShape​(org.w3c.dom.Document doc,
                                org.w3c.dom.Element parent,
                                Shape aShape)
        Add shape to XML document
        Parameters:
        doc - XML document
        parent - Parent XML element
        aShape - The shape
      • addLegend

        protected void addLegend​(org.w3c.dom.Document doc,
                                 org.w3c.dom.Element parent,
                                 ColorBreak aLegend,
                                 ShapeTypes shapeType)
        Add legend to XML document
        Parameters:
        doc - XML document
        parent - Parent XML element
        aLegend - The legend
        shapeType - The shape type
      • importFromXML

        public void importFromXML​(org.w3c.dom.Element graphicNode)
        Import from xml node
        Parameters:
        graphicNode - Graphic xml node
      • loadShape

        protected Shape loadShape​(org.w3c.dom.Node shapeNode)
      • loadLegend

        protected ColorBreak loadLegend​(org.w3c.dom.Node legendNode,
                                        ShapeTypes shapeType)