StateBuilder: all events type

Add explicit type signature to allEventsHandler to ensure
the handler method take obj. Previously it could be passed a method
that tried to coerce object at runtime.