public Messages(DatingProfile sender, string messageTitle, string messageData) { this.sender = sender; this.messageTitle = messageTitle; this.messageData = messageData; isRead = false; }
static void Main(string[] args) { DatingProfile Seth = new DatingProfile("Seth", "Quincy", 27, "Male"); Seth.WriteBio("Loves to sit down for hours and talk about the philisophical implications of eating."); DatingProfile Jessica = new DatingProfile("Jessica", "Meitner", 30, "Female"); Jessica.WriteBio("Loves to go to the mall and watch people, watch people."); DatingProfile Laura = new DatingProfile("Laura", "Shultz", 22, "Female"); Laura.WriteBio("Loves to talk about the affect of piano on the human psyche in the 18th Century."); Seth.SendMessage("What's up Jessica?", "Lets go to the mall.", Jessica); Jessica.ReadMessage(); Jessica.SendMessage("Hi Seth, sure let's go.", "At 8?", Seth); Seth.ReadMessage(); Seth.SendMessage("Hi Laura.", "Thats a nice piano you have there.", Laura); Laura.ReadMessage(); Laura.SendMessage("Hiya Seth.", "Thanks :) it was my grandma's.", Seth); Seth.ReadMessage(); }
static void Main(string[] args) { DatingProfile profile1 = new DatingProfile("Brad", "Johnson", 22, "male"); profile1.WriteBio("I Like Dogs."); DatingProfile profile2 = new DatingProfile("Erica", "Bennet", 24, "female"); profile2.WriteBio("I Like Cats."); profile1.SendMessage("Hello", "How are you?", profile2); profile2.ReadMessage(); }
static void Main(string[] args) { DatingProfile Jimi = new DatingProfile("Jimi", "Hendrix", 27, "Male"); Jimi.WriteBio("Excuse me while I kiss the sky"); DatingProfile Kurt = new DatingProfile("Kurt", "Kobain", 27, "Male"); Kurt.WriteBio("I've been trapped inside this heart shaped box"); Jimi.SendMessage("Hello Kurt", "Let's play some music.", Kurt); Kurt.ReadMessage(); }
static void Main(string[] args) { DatingProfile Lisa = new DatingProfile("Lisa", "Rolfe", 55, "Female"); Lisa.WriteBio("I love dogs."); DatingProfile Kurt = new DatingProfile("Kurt", "Kutschke", 58, "Male"); Kurt.WriteBio("I drive a corvette."); Kurt.SendMessage("Hey Lisa", "Do you like weiner dogs?", Lisa); Lisa.ReadMessage(); }
static void Main(string[] args) { DatingProfile supes = new DatingProfile("Clark", "Kent", 24, "Male"); supes.WriteBio("Mild mannered reporter for a major metropolitan newspaper"); DatingProfile babe = new DatingProfile("Lois", "Lane", 22, "Female"); babe.WriteBio("Hot headed damsel in distress"); supes.SendMessage("Hello Lois", "You know you are my kryptonite", babe); babe.ReadMessage(); }
public void SendMessage(string messageTitle, string messageData, DatingProfile toProfile) { Messages message = new Messages(this, messageTitle, messageData); toProfile.AddToMessages(message); }
public void SendMessage(string messageTitle, string messageData, DatingProfile sentTo) { Messages message = new Messages(this, messageTitle, messageData); sentTo.AddToInbox(message); }