/// <summary>
        /// Returns a deep copy of this collection.
        /// </summary>
        /// <returns>The copied object.</returns>
        public override object Clone()
        {
            CoordinateList copy = (CoordinateList)base.Clone();

            foreach (Coordinate c in this)
            {
                copy.Add(c.Clone());
            }
            return(copy);
        }
        /// <summary>
        /// If the coordinate array argument has repeated points,
        /// constructs a new array containing no repeated points.
        /// Otherwise, returns the argument.
        /// </summary>
        /// <param name="coord"></param>
        /// <returns></returns>
        public static ICoordinate[] RemoveRepeatedPoints(ICoordinate[] coord)
        {
            if (!HasRepeatedPoints(coord))
            {
                return(coord);
            }
            CoordinateList coordList = new CoordinateList(coord, false);

            return(coordList.ToCoordinateArray());
        }