Interface that allows you to create components with a method to clean their states.
Description
The ICleanable interface allows you to create components with a method to clean their states.
Instance methods
clear
Clears a component’s state.
Future clear(String? correlationId)
- correlationId: String? - (optional) transaction id used to trace execution through the call chain.
Examples
class MyObjectWithState implements ICleanable {
dynamic _state = {};
...
Future clear(String? correlationId) {
_state = {};
return Future();
}
}