public void apply(Object target) throws InvalidOrderingException {
        /*
         * Note that some subclasses of Ordering override apply(). The Sorter
         * subclass of Ordering overrides apply() to apply the sort (this is
         * done because sorting is more efficient than ordering).
         */
        if (target instanceof Orderable) {
            Orderable orderable = (Orderable) target;
            orderable.order(new Orderer(this));
        }
    }
public void apply ( Object target ) throws InvalidOrderingException { if ( target instanceof Orderable ) { Orderable orderable = ( Orderable ) target ; orderable . order ( new Orderer ( this ) ) ; } }
Order the tests in <code>target</code> using this ordering.

@throws InvalidOrderingException if ordering does something invalid (like remove or add
children)