Cancel operation

Usage


final cancelable = Cancelable();

final disposable = cancelable.whenCancel((){
    // cancel your operation
});
// do someing

dispose cancelletion

disposable.dispose();

cancel operation

cancelable.cancel();

Libraries

cancelable