ICleanable

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.

void clear(IContext context)

  • context: IContext - (optional) execution context to trace execution through call chain.

Examples

class MyObjectWithState implements ICleanable {
    private Object state = new Object();
    ...
    public void clear(IContext context) {
        this.state =  Object();
    }
}

See also