Code Duplication    Length = 10-10 lines in 2 locations

src/Polygon.php 1 location

@@ 248-257 (lines=10) @@
245
     *
246
     * @return Polygon
247
     */
248
    public function getReverse(): Polygon
249
    {
250
        $reversed = new static();
251
252
        foreach (array_reverse($this->points) as $point) {
253
            $reversed->addPoint($point);
254
        }
255
256
        return $reversed;
257
    }
258
}
259

src/Polyline.php 1 location

@@ 106-115 (lines=10) @@
103
     *
104
     * @return Polyline
105
     */
106
    public function getReverse(): Polyline
107
    {
108
        $reversed = new static();
109
110
        foreach (array_reverse($this->points) as $point) {
111
            $reversed->addPoint($point);
112
        }
113
114
        return $reversed;
115
    }
116
}
117