What are listeners in TestNG?

What are listeners in TestNG?

Listeners are an important feature of the TestNG framework. It’s a user interface that listens for preset events in test scripts and adjusts the TestNG tool’s default behaviour.