示例#1
0
 public Wall(Point from, Point to)
 {
     if (from.Equals(to))
     {
         throw new ZeroLengthWallException();
     }
     heightValue = 3;
     widthValue  = 0.20F;
     if (from.IsCloserToOriginThan(to))
     {
         beginningPoint = from;
         endPoint       = to;
     }
     else
     {
         beginningPoint = to;
         endPoint       = from;
     }
 }
示例#2
0
 private bool BelongsToEdge(Point aPoint)
 {
     return(aPoint.Equals(Beginning()) || aPoint.Equals(End()));
 }