core/src/com/google/inject/internal/Scoping.java
static Scoping makeInjectable(Scoping scoping, InjectorImpl injector, Errors errors) {
    Class<? extends Annotation> scopeAnnotation = scoping.getScopeAnnotation();
    if (scopeAnnotation == null) {
      return scoping;
    }

    ScopeBinding scope = injector.state.getScopeBinding(scopeAnnotation);
    if (scope != null) {
      return forInstance(scope.getScope());
    }

    errors.scopeNotFound(scopeAnnotation);
    return UNSCOPED;
  }
static Scoping makeInjectable(Scoping scoping, InjectorImpl injector, Errors errors) {
    Class<? extends Annotation> scopeAnnotation = scoping.getScopeAnnotation();
    if (scopeAnnotation == null) {
      return scoping;
    }

    ScopeBinding scope = injector.state.getScopeBinding(scopeAnnotation);
    if (scope != null) {
      return forInstance(scope.getScope());
    }

    errors.scopeNotFound(scopeAnnotation);
    return UNSCOPED;
  }
static Scoping makeInjectable ( Scoping scoping , InjectorImpl injector , Errors errors ) { Class < ? extends Annotation > scopeAnnotation = scoping . getScopeAnnotation ( ) ; if ( scopeAnnotation == null ) { return scoping ; } ScopeBinding scope = injector . state . getScopeBinding ( scopeAnnotation ) ; if ( scope != null ) { return forInstance ( scope . getScope ( ) ) ; } errors . scopeNotFound ( scopeAnnotation ) ; return UNSCOPED ; }
Replaces annotation scopes with instance scopes using the Injector's annotation-to-instance
map. If the scope annotation has no corresponding instance, an error will be added and unscoped
will be retuned.
Replaces annotation scopes with instance scopes using the Injector s annotation - to - instance map . If the scope annotation has no corresponding instance an error will be added and unscoped will be retuned .