public string Resolve(string file) { string resolved; if (TempFileResolutionCache.TryGetValue(file, out resolved)) { return(resolved); } return(ResolveWebResource(file)); }
public string Resolve(string file) { var split = file.Split(new[] { "://" }, StringSplitOptions.None); var assemblyName = split.ElementAt(0); var assembly = AppDomain.CurrentDomain.GetAssemblies().SingleOrDefault(x => x.GetName().Name == assemblyName); var resourceName = CalculateResourceName(assemblyName, split.ElementAt(1)); string resolved; if (TempFileResolutionCache.TryGetValue(resourceName, out resolved)) { return(resolved); } return(ResolveFile(file, assembly, resourceName)); }