Exemplo n.º 1
0
Arquivo: Rect.cs Projeto: ipzPZ121/OOP
 public Rect(Dot a, Dot b, Dot c, Dot d)
 {
     this.a = a;
     this.b = b;
     this.c = c;
     this.d = d;
 }
Exemplo n.º 2
0
 public Elips(Dot a, Dot b, Dot c, Dot d)
     : base(a, b , c ,d)
 {
     this.a = a;
     this.b = b;
     this.c = c;
     this.d = d;
 }
Exemplo n.º 3
0
 public Round(Dot a, Dot b, Dot c, Dot d)
     : base(a, b, c, d)
 {
     this.a = a;
     this.b = b;
     this.c = c;
     this.d = d;
     radius = a.getLengthTo(b) / 2;
     if(a.getLengthTo(b)!=c.getLengthTo(d))
         throw new System.ArgumentOutOfRangeException("Sides can't be different");
 }
Exemplo n.º 4
0
Arquivo: Dot.cs Projeto: ipzPZ121/OOP
 public double getLengthTo(Dot b)
 {
     return Math.Sqrt(Math.Pow((b.x1 - x1), 2) + Math.Pow((b.y1 - y1), 2));
 }