Skip to content

Instantly share code, notes, and snippets.

@ianloic
Created June 7, 2018 20:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ianloic/8ef9fd97142b5f5a888c7f47f61c9837 to your computer and use it in GitHub Desktop.
Save ianloic/8ef9fd97142b5f5a888c7f47f61c9837 to your computer and use it in GitHub Desktop.
import 'dart:async';
import 'other.dart' show Error;
abstract class Wlan {
Future<Error> method();
}
class WlanFuturize {
final Wlan _inner;
WlanFuturize(this._inner);
void method(void callback(Error error)) =>
_inner.method().then((Error _response) => callback(_response));
}
class Error {}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment