com.supermap.data

Class GeoCardinal



  • public class GeoCardinal
    extends Geometry
    The 2D Cardinal spline geometry class. This class is mainly used for CAD layer, it is the sub object of the object Geometry.
    • Constructor Detail

      • GeoCardinal

        public GeoCardinal()
        Create a new GeoCardinal object.
      • GeoCardinal

        public GeoCardinal(GeoCardinal geoCardinal)
        Create a new GeoCardinal object that is the same with the given GeoCardinal object.
        Parameters:
        geoCardinal - the specified GeoCardinal object.
      • GeoCardinal

        public GeoCardinal(Point2Ds controlPoints)
        Create a new GeoCardinal object with the given parameters.
        Parameters:
        controlPoints - control Points
    • Method Detail

      • getLength

        public double getLength()
        Returns the length of the 2D GeoCardinal object.
        Returns:
        the length of the 2D GeoCardinal object.
        Default:
        The default value is 0.
      • getControlPoints

        public Point2Ds getControlPoints()
        Returns the control point set.
        Returns:
        Control point collection.
        Default:
        The default value is an empty Point2Ds object.
      • setControlPoints

        public void setControlPoints(Point2Ds point2Ds)
        Sets the control point set.
        Parameters:
        point2Ds - The control point set.
      • convertToLine

        public GeoLine convertToLine(int pointCountPerSegment)
        Converts the GeoCardinal object to the GeoLine object.
        Parameters:
        pointCountPerSegment - the number of vertices between two neighbor control points.
        Returns:
        The line geometrical object.
      • setEmpty

        public void setEmpty()
        Clear 2D Cardinal spline.
        Overrides:
        setEmpty in class Geometry
      • isEmpty

        public boolean isEmpty()
        Returns whether the 2D Cardinal spline is null.
        Overrides:
        isEmpty in class Geometry
        Returns:
        A boolean, whether the 2D Cardinal spline returned is empty, true means is empty.
      • dispose

        public void dispose()
        Disposes the resources occupied by the object. After calling this method, this object will not be usable.
        Overrides:
        dispose in class Geometry
      • clone

        public GeoCardinal clone()
        Returns a copy of the current GeoCardinal object.
        Specified by:
        clone in class Geometry
        Returns:
        The new GeoCardinal object generated from the clone operation.