-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathHuman.cs
More file actions
57 lines (56 loc) · 1.97 KB
/
Human.cs
File metadata and controls
57 lines (56 loc) · 1.97 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
using Helper;
using System;
using System.Collections.Generic;
namespace EntityNamespace
{
public class Human : object
{
public static int StaticID { get; set; } = 0;
public int MyId { get; set; }
public string Name { get; set; }
public string Surname { get; set; }
public int Age { get; set; }
public string Username { get; set; }
public string Password { get; set; }
public string City { get; set; }
public string Phone { get; set; }
public List<Notification> Notifications { get; set; } = new List<Notification>();
public Human(string name, string surname, int age, string username, string password, string city, string phone)
{
MyId = StaticID++;
Name = name;
Surname = surname;
Username = username;
Password = password;
City = city;
Phone = phone;
Age = age;
}
public void SeeNotifications()
{
VisualHelper.ShowMyNotificationsScript();
if (Notifications.Count == 0)
{
Console.ForegroundColor = ConsoleColor.Red;
Console.WriteLine(" THERE IS NO NOTIFICATION HERE :(");
Console.WriteLine("\n Press Any Key To Continue . . .");
}
else
{
int rank = 1;
foreach (Notification notification in Notifications)
{
Console.ForegroundColor = ConsoleColor.Green;
Console.WriteLine($" Message {rank}");
Console.ForegroundColor = ConsoleColor.Yellow;
Console.WriteLine(notification);
rank++;
}
Console.WriteLine("\nPress Any Key To Continue . . .");
Console.SetCursorPosition(0, 0);
Console.WriteLine("");
}
Console.ReadKey();
}
}
}