made the BezierClass to be a template to hold all data