? -(void) setupGroup1
{
//1. Create a group
lkcommongroup *group = [lkcommongroup Group];
[self. groups addobject: group];
//2. set up all row data for a group
lkcommonarrowitem *clearcache = [lkcommonarrowitem itemwithtitle< /c5>:@ " clear Image cache "];
// Set the size of the cache
NSString *caches = [Nssearchpathfordirectoriesindomains (nscachesdirectory, Nsuserdomainmask, YES) lastObject];
[Caches stringbyappendingpathcomponent:@ "Com.hackemist.SDWebImageCache.default"];
& nbsp nsstring *imagecachepath = [ sdimagecache &NBSP; sharedimagecache diskcachepath
long long fileSize = [Imagecachepath fileSize];
& nbsp ClearCache. subtitle = [ NSString &NBSP; stringWithFormat : @ "(%.1FM)" 1000.0 &NBSP;*&NBSP; 1000.0 )];
__weak typeof(clearcache) Weakclearcache = ClearCache;
__weak typeof (self) weakvc = self;
ClearCache. Operation = ^{
[mbprogresshud showmessage:@ " clearing cache ... " ];
// Clear Cache
nsfilemanager *mgr = [nsfilemanager defaultmanager];
[Mgr removeitematpath: Imagecachepath error:nil];
// set subtitle
Weakclearcache. subtitle = Nil ;
// Refresh table
[WEAKVC. TableView reloaddata];
[mbprogresshud hidehud];
};
Group. Items = @[clearcache] ;
//Lklog (@ "%lld", [@ "/users/apple/desktop/ music " fileSize]);
}
Clear the picture cache