curves function

Curve? curves(
  1. String type,
  2. dynamic a,
  3. dynamic b,
  4. dynamic c,
  5. dynamic d,
  6. dynamic e,
  7. dynamic f,
)

Implementation

Curve? curves(String type,a,b,c,d,e,f){
  switch (type) {
    case 'ArcCurve':
      return ArcCurve(a,b,c,d,e,f);
    case 'CatmullRomCurve3':
      return CatmullRomCurve3(points: a,closed: b, curveType: c, tension: d);
    case 'CubicBezierCurve':
      return CubicBezierCurve(a,b,c,d);
    case 'CubicBezierCurve3':
      return CubicBezierCurve3(a,b,c,d);
    case 'EllipseCurve':
      return EllipseCurve(a,b,c,d,e,f);
    case 'LineCurve':
      return LineCurve(a,b);
    case 'LineCurve3':
      return LineCurve3(a,b);
    case 'QuadraticBezierCurve3':
      return QuadraticBezierCurve3(a,b,c);
    case 'QuadraticBezierCurve':
      return QuadraticBezierCurve(a,b,c);
    case 'SplineCurve':
      return SplineCurve(a);
    default:
      return null;
  }
}