Exemplo n.º 1
0
 /// <summary>
 /// Add an event to the current instance.
 /// </summary>
 /// <param name="date">Date of the event</param>
 /// <param name="title">The title of the event</param>
 /// <param name="location">The location of the event</param>
 public void AddEvent(DateTime date, string title, string location)
 {
     Event newEvent = new Event(date,title,location);
     byTitle.Add(title.ToLower(),newEvent);
     byDate.Add(newEvent);
     Messages.EventAdded();
 }
Exemplo n.º 2
0
 public static void PrintEvent(Event eventToPrint)
 {
     if (eventToPrint != null)
     {
         output.Append(eventToPrint + Environment.NewLine);
     }
 }
Exemplo n.º 3
0
 /// <summary>
 /// Appends <see cref="Event"/> info to the <see cref="StringBuilder"/> reference - <see cref="Output"/>
 /// </summary>
 /// <param name="eventToPrint"></param>
 public static void PrintEvent(Event eventToPrint)
 {
     if (eventToPrint != null)
     {
         Output.Append(eventToPrint + "\n");
     }
 }