Beispiel #1
0
 public Messages(DatingProfile sender, string messageTitle, string messageData)
 {
     this.sender       = sender;
     this.messageTitle = messageTitle;
     this.messageData  = messageData;
     isRead            = false;
 }
Beispiel #2
0
        static void Main(string[] args)
        {
            DatingProfile bob = new DatingProfile("Mark", "Slone", 40, "Male");

            bob.WriteBio("New to this online dating.");

            DatingProfile susie = new DatingProfile("Lexie", "Grey", 25, "Female");

            susie.WriteBio("Love to read and write.");

            bob.SendMessage("Hello Lexie", "When is the new book coming out?", susie);
            susie.ReadMessage();
        }
Beispiel #3
0
        public void SendMessage(string messageTitle, string messageData, DatingProfile sentTo)
        {
            Messages message = new Messages(this, messageTitle, messageData);

            sentTo.AddToInbox(message);
        }