Order by inheritance hierarchy.