private void CacheComplete(IResolverContext context, IDependencyResolver resolver)
 {
     if (context.IsSingletonLifetime())
     {
         DependencyTableHelper.AddScoped(_dependencyTable, context, null);
     }
     if (context.IsScopedLifetime())
     {
         DependencyTableHelper.AddScoped(_dependencyTable, context, resolver);
     }
 }
 private void CacheResolved(IResolverContext context, IDependencyResolver resolver)
 {
     if (context.IsSingletonLifetime())
     {
         ScopedCacheManager.SetCache(((DependencyResolver) resolver).RootScoped, context.Dependency,
             context.Resolved);
     }
     if (context.IsScopedLifetime())
     {
         ScopedCacheManager.SetCache((IScopedResolver) resolver, context.Dependency, context.Resolved);
     }
 }
 public bool Requires(IResolverContext context, IDependencyResolver resolver)
 {
     return context.NotResolved() && context.IsScopedLifetime();
 }