Looking for some insight on if this is possible or not. I am trying preload my NSURLCache with a Cache.DB that is already filled with caches from a uiwebview. I don't see why this can't be possible since the Apple documentation states that the diskPath:
"In iOS, path is the name of a subdirectory of the application’s default cache directory in which to store the on-disk cache (the subdirectory is created if it does not exist)."
So what I did was copy the whole Cache folder as a referenced folder to my application bundle and used the path in the code below. However, I am unable to pull the caches. The path location to the cache files is correct as I printed it out.. Any idea?
Also please don't mention EVURLCache I already looked into that.
NSString *cacheDir = [[[NSBundle mainBundle] bundlePath] stringByAppendingPathComponent:@"Caches"
NSURLCache *URLCache = [[NSURLCache alloc] initWithMemoryCapacity:4 * 1024 * 1024
diskCapacity:20 * 1024 * 1024
diskPath:cacheDir;
[NSURLCache setSharedURLCache:URLCache];