-
Notifications
You must be signed in to change notification settings - Fork 0
/
HoneymoonPackage.cs
68 lines (63 loc) · 2.52 KB
/
HoneymoonPackage.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
using System;
namespace Tourism_System__Sda_Project_
{
public class HoneymoonPackage : I_TourPackage
{
private static int totalHoneymoonPackagesSold = 0;
private static int totalHoneymoonRevenue = 0;
private static int latestHoneymoonRevenue = 0;
private static int oldHoneymoonRevenue = 0;
private string hLocation = "any";
private int NoofBeds = 01;
private string FoodIncluded = "Yes";
private int price = 17000;
public HoneymoonPackage()
{
}
public HoneymoonPackage(string tempLoc)
{
hLocation = tempLoc;
}
public void setLocation(string tempLoc)
{
hLocation = tempLoc;
}
public int getPrice()
{
return price;
}
public void DisplayPackageDetails()
{
Console.WriteLine("╔════════════════════════════════════════════════╗");
Console.WriteLine("║ Honeymoon Package: Romantic travel experience ║");
Console.WriteLine("╚════════════════════════════════════════════════╝");
Console.WriteLine();
Console.WriteLine(" Travel Destination: " + hLocation);
Console.WriteLine(" Beds Included: " + NoofBeds);
Console.WriteLine(" Food Included: " + FoodIncluded);
Console.WriteLine(" Price of Package: " + price);
Console.WriteLine("-------------------------------------------------");
Console.WriteLine();
}
public int GetTotalPackagesSent()
{
return totalHoneymoonPackagesSold;
}
public void getOldRev()
{
Console.WriteLine("Old Revenue of Honeymoon Package is: " + oldHoneymoonRevenue);
}
public void getNewRev()
{
Console.WriteLine("New Revenue of Honeymoon Package is: " + latestHoneymoonRevenue);
}
public int CalculateOverallRevenue(int honeymoonPackagesSold)
{
oldHoneymoonRevenue = totalHoneymoonRevenue;
totalHoneymoonPackagesSold += honeymoonPackagesSold;
latestHoneymoonRevenue = honeymoonPackagesSold * price;
totalHoneymoonRevenue += latestHoneymoonRevenue;
return totalHoneymoonRevenue;
}
}
}