Registers a output listener with this task. Quicker way of hooking into output events is using the onOutput method.
The listener to add.