use<T> method

  1. @override
T use<T>()

Implementation

@override
T use<T> () {
  if (!_states.containsKey(T)) {
    throw NotExistException('The shared state named $T does not exist on your project.');
  }

  return _states[T] as T;
}