예제 #1
0
        static void Main(string[] args)
        {
            var emily = new Tweeter();

            var worshiperOfAllThingsEmily         = new Follower(emily);
            var iWantToBeJustLikeEmilyWhenIGrowUp = new Follower(emily);
            var ardentFollowerOfEmily             = new Follower(emily);

            emily.Tweet = new Tweet
            {
                Author          = "Emily",
                PublicationTime = DateTime.Now,
                Text            = "Words of great wisdom"
            };

            Console.ReadLine();
        }
예제 #2
0
        static void Main(string[] args)
        {
            var emily = new Tweeter();

            var worshiperOfAllThingsEmily = new Follower(emily);
            var iWantToBeJustLikeEmilyWhenIGrowUp = new Follower(emily);
            var ardentFollowerOfEmily = new Follower(emily);

            emily.Tweet = new Tweet
            {
                Author = "Emily",
                PublicationTime = DateTime.Now,
                Text = "Words of great wisdom"
            };

            Console.ReadLine();
        }
예제 #3
0
 public Follower(Tweeter tweeter)
 {
     tweeter.TweetPublished += Update;
 }
예제 #4
0
 public Follower(Tweeter tweeter)
 {
     tweeter.TweetPublished += Update;
 }