added getProductInfo functions
cleaned the __init__ method
separated tree class in its own file