001// Licensed under the MIT license. See LICENSE file in the project root for full license information. 002 003package de.bytefish.pgbulkinsert.pgsql.model.geometric; 004 005import java.util.List; 006 007public class Path { 008 009 private final boolean isClosed; 010 private final List<Point> points; 011 012 public Path(boolean closed, List<Point> points) { 013 014 if(points == null) { 015 throw new IllegalArgumentException("points"); 016 } 017 018 this.isClosed = closed; 019 this.points = points; 020 } 021 022 public boolean isClosed() { 023 return isClosed; 024 } 025 026 public List<Point> getPoints() { 027 return points; 028 } 029 030 public int size() { 031 return points.size(); 032 } 033}