Exemple #1
0
		/// <summary>
		///  конструктор класса
		/// </summary>
		public Person(string n)
		{
			TimeEvent args = new TimeEvent();
			name = n;
			args.TimeReached = DateTime.Now;
			if (args.TimeReached.Hour < 12)
				greet = "Доброе утро";
			else if (args.TimeReached.Hour < 17)
				greet = "Добрый день";
			else greet = "Добрый вечер";
			OnCame(args);
		}
Exemple #2
0
		public virtual void OnCame(TimeEvent e)
		{
				CameToWork();
			if (Came != null)
				Came(this, e);
		}