Package org.testng

Interface ListenerComparator

All Superinterfaces:
Comparator<ITestNGListener>
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public interface ListenerComparator extends Comparator<ITestNGListener>
Listener interface that can be used to determine listener execution order. This interface will NOT be used to determine execution order for IReporter implementations.

An implementation can be plugged into TestNG either via:

  1. TestNG.setListenerComparator(ListenerComparator) if you are using the TestNG APIs.
  2. Via the configuration parameter -listenercomparator if you are using a build tool