package binary_tree;

public class LinkedBinaryTree<E> implements BinaryTree<E>{
	
	// VARIABILI D'INSTANZA
	private BinaryNode<E> root;
	private int size;
	
	// Metodi costruttori
	public LinkedBinaryTree() {
		root = null;
		size = 0;
	}
	
	public LinkedBinaryTree(E data) {
		root = new BinaryNode<E>(data);
		size = 1;
	}
	
	public LinkedBinaryTree(LinkedBinaryTree<E> left, E data, LinkedBinaryTree<E> right) {
		root = new BinaryNode<E>(left.root, data, right.root);
		size = 1 + left.size + right.size;
	}
	
	// METODI
	
	public int size() {
		return size;
	}
	
	public boolean isEmpty() {
		return (size == 0);
	}
	
	@Override
	public boolean isEmpty() {
		
	}
	
}
