-
Notifications
You must be signed in to change notification settings - Fork 0
/
PlatinumPackage.cs
69 lines (63 loc) · 2.5 KB
/
PlatinumPackage.cs
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
58
59
60
61
62
63
64
65
66
67
68
69
using System;
namespace Tourism_System__Sda_Project_
{
public class PlatinumPackage : I_TourPackage
{
private static int totalPlatinumPackagesSold = 0;
private static int totalPlatinumRevenue = 0;
private static int latestPlatinumRevenue = 0;
private static int oldPlatinumRevenue = 0;
private string pLocation = "any";
private int NoofBeds = 04;
private string FoodIncluded = "Yes";
private int price = 15000;
public PlatinumPackage()
{
}
public PlatinumPackage(string tempLoc)
{
pLocation = tempLoc;
}
public void DisplayPackageDetails()
{
Console.WriteLine("╔════════════════════════════════════════════════╗");
Console.WriteLine("║ Platinum Package: Premium travel experience ║");
Console.WriteLine("╚════════════════════════════════════════════════╝");
Console.WriteLine();
Console.WriteLine(" Travel Destination: " + pLocation);
Console.WriteLine(" Beds Included: " + NoofBeds);
Console.WriteLine(" Food Included: " + FoodIncluded);
Console.WriteLine(" Price of Package: " + price);
Console.WriteLine("-------------------------------------------------");
Console.WriteLine();
}
public void setLocation(string tempLoc)
{
pLocation = tempLoc;
}
public int getPrice()
{
return price;
}
public int GetTotalPackagesSent()
{
return totalPlatinumPackagesSold;
}
public void getOldRev()
{
Console.WriteLine("Old Revenue of Platinum Package is: " + oldPlatinumRevenue);
}
public void getNewRev()
{
Console.WriteLine("New Revenue of Platinum Package is: " + latestPlatinumRevenue);
}
public int CalculateOverallRevenue(int platinumPackagesSold)
{
oldPlatinumRevenue = totalPlatinumRevenue;
totalPlatinumPackagesSold += platinumPackagesSold;
latestPlatinumRevenue = platinumPackagesSold * price;
totalPlatinumRevenue += latestPlatinumRevenue;
return totalPlatinumRevenue;
}
}
}