class PointNode { constructor(x, y, attributes) { this.setPosition(x, y); this.attributes = attributes; } setPosition(x, y) { this.x = x; this.y = y; } setAttribute(key, value) { this.attributes[key] = value; } }