Submission directions at end of this assignment.
interface ActionListener {
void actionPerformed(ActionEvent e);
void buttonClicked(ActionEvent e);
}
class Actor implements ActionListener {
public Actor();
public void actionPerformed(ActionEvent e);
void buttonClicked(ActionEvent e);
public void displayBanner(String banner);
}
Answer the following questions:
DrawArc(left, top, width, height, angle1, angle2)angle1 and angle2 denote the beginning and ending angle of the arc. An oval can be created by setting angle1 to 0 and angle2 to 360. A circle can be similarly created, except that in addition the width must equal the height.
The format of this command could lead you to define a class hierarchy in which an oval is a subclass of an arc, and a circle is a subclass of an oval:
arc | oval | circle
The oval subclass does not want to provide either the SetAngle1 or SetAngle2 methods because it is a closed arc. The circle subclass additionally wants to eliminate the setWidth and setHeight methods and add a setDiameter method. Answer the following questions:
package LinkedList;
class ListNode {
protected int value;
String name;
}
package LinkedList;
public class List {
ListNode header;
protected ListNode sentinelNode;
public List() {
header = new ListNode();
1) header.value = 10;
2) header.name = "brad";
sentinelNode = new ListNode();
}
}
package LinkedQueue;
class Queue extends LinkedList.List {
public Queue() {
3) header.value = 20;
4) sentinelNode.value = 30;
}
}
Answer the following yes/no questions about the above code and for each
answer explain why you answered as you did:
3 10 5 6 9 12
Submit three files: