Frank Moreno

exporting and using ValueUpdater

@@ -5,3 +5,5 @@ export 'src/get_main.dart'; @@ -5,3 +5,5 @@ export 'src/get_main.dart';
5 export 'src/log.dart'; 5 export 'src/log.dart';
6 6
7 export 'src/smart_management.dart'; 7 export 'src/smart_management.dart';
  8 +
  9 +export 'src/typedefs.dart';
1 -import 'package:flutter/material.dart'; 1 +import 'package:meta/meta.dart';
  2 +import '../../get_core/get_core.dart';
2 3
3 /// Special callable class to keep the contract of a regular method, and avoid 4 /// Special callable class to keep the contract of a regular method, and avoid
4 /// overrides if you extend the class that uses it, as Dart has no final 5 /// overrides if you extend the class that uses it, as Dart has no final
5 /// methods. 6 /// methods.
6 /// Used in [DisposableInterface] to avoid the danger of overriding onStart. 7 /// Used in [DisposableInterface] to avoid the danger of overriding onStart.
7 class _InternalFinalCallback<T> { 8 class _InternalFinalCallback<T> {
8 - ValueGetter<T> _callback; 9 + ValueUpdater<T> _callback;
9 10
10 - _InternalFinalCallback({ValueGetter<T> callback}) : _callback = callback; 11 + _InternalFinalCallback({ValueUpdater<T> callback}) : _callback = callback;
11 12
12 T call() => _callback.call(); 13 T call() => _callback.call();
13 } 14 }