listing continued /private void preorder(node localrootif(localroot !nullsystem out print(localroot idata ")preorder(localroot leftchild)preorder(localroot rightchild)/private void inorder(node localrootif(localroot !nullinorder(localroot leftchild)system out print(localroot idata ")inorder(localroot rightchild)/private void postorder(node localrootif(localroot !nullpostorder(localroot leftchild)postorder(localroot rightchild)system out print(localroot idata ")/public void displaytree(stack globalstack new stack()globalstack push(root)int nblanks boolean isrowempty falsesystem out println")while(isrowempty==false