setMockMessageHandler method Null safety
- Future<
T> handler(- T? message
Shim for TestDefaultBinaryMessenger.setMockDecodedMessageHandler
.
Implementation
// HYPERLINK ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
// TODO(ianh): deprecate this method: @NotYetDeprecated(
// 'Use tester.binding.defaultBinaryMessenger.setMockDecodedMessageHandler or '
// 'TestDefaultBinaryMessengerBinding.instance.defaultBinaryMessenger.setMockDecodedMessageHandler instead. '
// 'This feature was deprecated after v2.1.0-10.0.pre.'
// )
void setMockMessageHandler(Future<T> Function(T? message)? handler) {
TestDefaultBinaryMessengerBinding.instance!.defaultBinaryMessenger.setMockDecodedMessageHandler<T>(this, handler);
}