Beispiel #1
0
        static void Main1(string[] args)
        {
            Ball ball = new Ball();
            Pitcher pitcher = new Pitcher(ball);

            BallEventArgs ballEventArgs = new BallEventArgs(45, 100);
            ball.OnBallInPlay(ballEventArgs);
        }
Beispiel #2
0
 public Pitcher(Ball ball)
 {
     ball.BallInPlay += new EventHandler(ball_BallInPlay);
 }