Create tree view with multiple doctypes

Can I create tree view with multiple doctypes? I want to create a tree view with Company, Branch, Departmennt and Designation. Is this possible? If possible, then how? Any idea?