ADT Binary Search tree: A binary search tree can be used to store a list of comparable objects. In a generic binary search tree class, constrain E(the type parameter) to be the class types that implement Comparable interface. In the class header, add the interface as the upper bound to E. public class BinarySearchTree> Specifications of the ADT binary search tree: • Construct a binary search tree. • Retrieve the root of this tree. • Change the root of this tree if supported. • Check if this tree is empty. • Make this tree empty. • Search an element in this tree. • Insert an element into this tree. • Delete an element from this tree. • Construct an iterator of this tree. • Get a reference to the element of a node. You should design these operations in bold in a super class and put the rest in a sub class. To support this class, the following classes must be designed and implemented: • Generic tree node class: a tree node contains an element, a left reference, and a right reference. • Generic tree iterator class: a class implementing Iterator interface and provides traversal operations. • Tree exception class: used for the abnormal situations from some tree operations.

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

Java coding

ADT Binary Search tree:
A binary search tree can be used to store a list of comparable objects. In a generic binary search tree class, constrain E(the type parameter) to be the class types that implement Comparable interface. In the class header, add the interface as the upper bound to E.
public class BinarySearchTree<E extends Comparable<E>>
Specifications of the ADT binary search tree:
• Construct a binary search tree.
• Retrieve the root of this tree.
• Change the root of this tree if supported.
• Check if this tree is empty.
• Make this tree empty.
• Search an element in this tree.
• Insert an element into this tree.
• Delete an element from this tree.
• Construct an iterator of this tree.
• Get a reference to the element of a node.
You should design these operations in bold in a super class and put the rest in a sub class. To support this class, the following classes must be designed and implemented:
• Generic tree node class: a tree node contains an element, a left reference, and a right reference.
• Generic tree iterator class: a class implementing Iterator interface and provides traversal operations.
• Tree exception class: used for the abnormal situations from some tree operations.

Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 2 steps

Blurred answer
Knowledge Booster
Operations of Linked List
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
  • SEE MORE 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