Interface Scope


public interface Scope
Scopes control the lifetime of instances with a ScopeType.
  • Method Summary

    Modifier and Type
    Method
    Description
    <T> Supplier<T>
    get(Key<T> key, Supplier<T> unscoped)
    Scopes an instance factory for the provided key and unscoped factory in this scope.
  • Method Details

    • get

      <T> Supplier<T> get(Key<T> key, Supplier<T> unscoped)
      Scopes an instance factory for the provided key and unscoped factory in this scope. The scoped factory should return a current scoped instance or create a new one using the unscoped factory.