Adds a callback that's invoked on state change.
A callback that's invoked on state change.
A function to remove the listener.
Adds a callback that's invoked on state change.