Exemple #1
0
        public IEnumerable <IResource> FindResources(ResourceType resourceType)
        {
            return(_resourceCache.GetOrAddResources(resourceType, () =>
            {
                var combined = new List <IResource>();
                foreach (IResourceFinder finder in _finders)
                {
                    var found = finder.FindResources(resourceType).Where(IsNotExcluded);
                    combined.AddRange(found);
                }

                return combined;
            }));
        }
Exemple #2
0
 public IEnumerable <IResource> FindResources(ResourceType resourceType)
 {
     return(_cache.GetOrAddResources(resourceType, () => _inner.FindResources(resourceType)));
 }