Question
Create a UML diagram for the following .java program. /** * NFLPlayer have its properties * and methods for setters and getters * @author your
Create a UML diagram for the following .java program.
/** * NFLPlayer have its properties * and methods for setters and getters * @author your name * */ public class NFLPlayer {
//properties of NFLPlayer private int id; private String name; private String teamName; private int score; //default constructor public NFLPlayer() {} //constructor with param //that initializes the all properties public NFLPlayer(int id, String name, String teamName, int score) { this.id = id; this.name = name; this.teamName = teamName; this.score = score; }
//accesser and mutators for properties public int getId() { return id; }
public void setId(int id) { this.id = id; }
public String getName() { return name; }
public void setName(String name) { this.name = name; }
public String getTeamName() { return teamName; }
public void setTeamName(String teamName) { this.teamName = teamName; }
public int getScore() { return score; }
public void setScore(int score) { this.score = score; } }
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started