do I create a high-level UML class diagram that represents the design of the code below? DETAILED PLEASE!! package animation; public abstract class Animation { protected int animationStartTime; protected int animationEndTime; public int getAnimationStartTime() {} public void setAnimationStartTime(int seconds) {} public int getAnimationEndTime() {} public void setAnimationEndTime(int seconds) {} public abstract void update(Shape shape, int seconds); } package animation; public class ChangeColorAnimation extends Animation {

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Question

How do I create a high-level UML class diagram that represents the design of the code below? DETAILED PLEASE!!

package animation;

public abstract class Animation {

protected int animationStartTime;

protected int animationEndTime;

public int getAnimationStartTime() {}

public void setAnimationStartTime(int seconds) {}

public int getAnimationEndTime() {}

public void setAnimationEndTime(int seconds) {}

public abstract void update(Shape shape, int seconds);

}

package animation;

public class ChangeColorAnimation extends Animation {

protected Color oldColor;

protected Color newColor;

public ChangeColorAnimation(Color oldColor, Color newColor) {}

@Override

public void update(Shape shape, int seconds) {}

@Override

public String toString() {}

}

package animation;

public class MoveAnimation extends Animation {

protected Point2D.Double oldPoint;

protected Point2D.Double newPoint;

public MoveAnimation(double x1, double y1, double x2, double y2) {}

@Override

public void update(Shape shape, int seconds) {}

@Override

public String toString() {}

}

package animation;

public class ScaleRectangleAnimation extends Animation {

private final double oldValue;

private final double newValue;

public final boolean scaleWidth;

public ScaleRectangleAnimation(boolean scaleWidth, double oldValue, double newValue) {}

@Override

public void update(Shape shape, int seconds) {}

@Override

public String toString() {}

}

package frame;

public class EasyAnimatorForm {

public EasyAnimatorForm() {}

}

package model;

public abstract class AnimationModel {

public abstract void play();

public abstract void stop();

public abstract void addShape(Shape shape);

public abstract void removeShape(String name);

public abstract String getAnimationDescription();

}

package model;

public class AnimationModelImpl extends AnimationModel {

private final HashMap shapeMap = new HashMap<>();

public AnimationModelImpl(String filePath) throws NoSuchFileException {}

@Override

public void play() {}

@Override

public void stop() {}

@Override

public void addShape(Shape shape) {}

@Override

public void removeShape(String name) {}

@Override

public String getAnimationDescription() {}

private void loadAnimationFile(String filePath) throws NoSuchFileException {}

private Point2D.Double getPointFromString(String s) {}

private String advanceReaderToToken(Scanner reader, String token) {}

private int getTime(String s) {}

private Color getColorFromName(String colorName) throws NoSuchFieldException,IllegalAccessException {}

}

package shapes;

public class Ellipse extends Shape {

private double boundingRectX;

private double boundingRectY;

protected double radiusX;

protected double radiusY;

public Ellipse(double x, double y, double radiusX, double radiusY) {}

public double getRadiusX() {}

public void setRadiusX(double radius) {}

public double getRadiusY() {}

public void setRadiusY(double radius) {}

@Override

public String toString() {}

@Override

public void draw(Graphics g) {}

}

package shapes;

public class Rectangle extends Shape {

protected double width;

protected double height;

public Rectangle(double x, double y, double width, double height) {}

public double getWidth() {}

public void setWidth(double width) {}

public double getHeight() {}

public void setHeight(double height) {}

@Override

public String toString() {}

@Override

public void draw(Graphics g) {}

}

package shapes;

public abstract class Shape {

protected String name;

protected Point2D.Double point;

protected Color color;

protected int animationStartTime;

protected int animationEndTime;

protected ArrayList animations = new ArrayList<>();

public String getName() {}

public void setName(String name) {}

public Point2D.Double getPoint() {}

public void setPoint(Point2D.Double point) {}

public void setLocation(double x, double y) {}

public Color getColor() {}

public void setColor(Color color) {}

public void setColor(float r, float g, float b) {}

public int getAnimationStartTime() {}

public void setAnimationStartTime(int seconds) {}

public int getAnimationEndTime() {}

public void setAnimationEndTime(int seconds) {}

public void addAnimation(Animation animation) {}

public ArrayList getAnimations() {}

public void update(int seconds) {}

public abstract void draw(Graphics g);

}

import model.AnimationModelImpl;

import org.junit.Test;

import java.nio.file.NoSuchFileException;

public class AnimationModelTests {

AnimationModelImpl animationModel;

@Test

public void testAnimationModelImpl() throws NoSuchFileException {}

}

Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 2 steps with 1 images

Blurred answer
Knowledge Booster
Managing System
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
Recommended textbooks for you
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education