import { Vector } from './vector' ; import { IPolyline , IPoint } from '../../interfaces' ; /**
 * Creates a polyline vector
 */ export class Polyline extends Vector < Polyline , IPolyline > { param points { Array < IPoint > } constructor ( points = [ ] ) { super ( 'polyline' ) ; this . content . points = points ; } /**
     * Closes the path
     */ public closePath ( ) { this . content . closePath = true ; return this ; } param x param y public addPoint ( x , y ) { this . content . points . push ( { x , y } ) ; return this ; } }