clear method

void clear()

Clears the state, resetting the registry and effectively restoring it to the state of a newly created DIRegistry instance.

Implementation

@pragma('vm:prefer-inline')
void clear() {
  _state.clear();
  _typeIndex.clear();
  _fireOnChange();
}