Combinatorial characterization of upward planarity