public class Stadium extends baseStadium{ public int typeTicket; int floors; int seating; String type; public float ticketPrice; public String leagueName=""; public void SetTecketName(String val) { leagueName=val; } public void setType() { if (typeTicket == 1) { type = "VIP"; } else { type = "Regular"; } } public String getType() { return type; } public void setPrice() { if (typeTicket == 1) { ticketPrice = 250; } else { ticketPrice = 100; }
OOPs
In today's technology-driven world, computer programming skills are in high demand. The object-oriented programming (OOP) approach is very much useful while designing and maintaining software programs. Object-oriented programming (OOP) is a basic programming paradigm that almost every developer has used at some stage in their career.
Constructor
The easiest way to think of a constructor in object-oriented programming (OOP) languages is:
public class Stadium extends baseStadium{ public int typeTicket; int floors; int seating; String type; public float ticketPrice; public String leagueName=""; public void SetTecketName(String val) { leagueName=val; } public void setType() { if (typeTicket == 1) { type = "VIP"; } else { type = "Regular"; } } public String getType() { return type; } public void setPrice() { if (typeTicket == 1) { ticketPrice = 250; } else { ticketPrice = 100; } } public void setFloors(int floors) { this.floors = floors; } public int getFloors() { return floors; } public void setSeating(int seating) { this.seating = seating; } public int getSeating() { return seating; } public void printDetails() { System.out.println("Ticket Details:"); System.out.println("Ticket Type: " + getType()); System.out.println("Floors: " + getFloors()); System.out.println("Seating: " + getSeating()); } public void printMatch() { System.out.println("Match: Manchester United vs Liverpool"); } public void printLeagueNane() { System.out.println("League Name:"+leagueName); } public void printData() { System.out.println("Date: 10th February 2023"); } public void printTime() { System.out.println("Time: 8:00 PM"); } public void printStadium() { System.out.println("Stadium: Old Trafford"); } public void printLocation() { System.out.println("Location: Manchester, England"); } } public class ticket implements TicketService { public int ticketNumber = 1234; public void PlusTictNo() { ticketNumber+=1; } //hrer Overloading on GenerateRandomNo method public int GenerateRandomNo() { Random rand = new Random(); int upperbound = 2515; int int_random = rand.nextInt(upperbound); return int_random; } public int GenerateRandomNo(int upper) { Random rand = new Random(); int int_random = rand.nextInt(upper); return int_random; } @Override public void PrintData(String val) { System.out.println(val); } } public interface TicketService { void PrintData(String val); } public abstract class baseStadium { abstract void printDetails() ; }//I want to draw an environmental scheme for this code, the example of the image, every separate class
![n of Saudi Arabia
Qura University
of Computing at Alqunfudha
er Science Department
Name:
Members( Name/Student ID):
s Description:
●
rogress, draw a class diagram to model your entire project, showing class attributes an
cions, roles and multiplicity.
.
nple:
Upload your class diagram as pdf or png file, including group members names a
name.
Customer
name: String
address
You can use Visual Paradigm - Online Office Suite (visual-paradigm.com) to draw
Cash
-cash Tendered: float
مشاركة
Order
جـامعـة ام الفـرى
ك الحب الي بالقسما
-date: Date
status: String
calcSub Tota)
calcTax
+calcTotal)
calcTotalWeight
Payment
-amount toat
Check
name String
-bankiD String
autorized
Semester 2. 1
Course: Ob
Project Mo
Group Project Number:
Progress:4
OrderDetail
quantit
ne temtaxStatus: String o
1caic Sub Total
calcWeight)
calcTa
Credit
name String
type Sting
Branwen
pate
authorized
عرض المحمول
tem
shipping Weight
description String
gelPricef or Quantity
gefa
inStock)
DO
DO
أدوات](/v2/_next/image?url=https%3A%2F%2Fcontent.bartleby.com%2Fqna-images%2Fquestion%2Fb2cea469-ad34-4d0f-9291-fc5db981c5dd%2F56ee0b6b-c9a9-4aaa-956e-77b5fbdcd543%2Fmxwugd_processed.jpeg&w=3840&q=75)
![](/static/compass_v2/shared-icons/check-mark.png)
Step by step
Solved in 2 steps
![Blurred answer](/static/compass_v2/solution-images/blurred-answer.jpg)
![Database System Concepts](https://www.bartleby.com/isbn_cover_images/9780078022159/9780078022159_smallCoverImage.jpg)
![Starting Out with Python (4th Edition)](https://www.bartleby.com/isbn_cover_images/9780134444321/9780134444321_smallCoverImage.gif)
![Digital Fundamentals (11th Edition)](https://www.bartleby.com/isbn_cover_images/9780132737968/9780132737968_smallCoverImage.gif)
![Database System Concepts](https://www.bartleby.com/isbn_cover_images/9780078022159/9780078022159_smallCoverImage.jpg)
![Starting Out with Python (4th Edition)](https://www.bartleby.com/isbn_cover_images/9780134444321/9780134444321_smallCoverImage.gif)
![Digital Fundamentals (11th Edition)](https://www.bartleby.com/isbn_cover_images/9780132737968/9780132737968_smallCoverImage.gif)
![C How to Program (8th Edition)](https://www.bartleby.com/isbn_cover_images/9780133976892/9780133976892_smallCoverImage.gif)
![Database Systems: Design, Implementation, & Manag…](https://www.bartleby.com/isbn_cover_images/9781337627900/9781337627900_smallCoverImage.gif)
![Programmable Logic Controllers](https://www.bartleby.com/isbn_cover_images/9780073373843/9780073373843_smallCoverImage.gif)