Get List of All Installed Application in iOS 8

Get list of all installed application in ios 8

try this.
it works,I've tested.

#include <objc/runtime.h>
Class LSApplicationWorkspace_class = objc_getClass("LSApplicationWorkspace");
NSObject* workspace = [LSApplicationWorkspace_class performSelector:@selector(defaultWorkspace)];
NSLog(@"apps: %@", [workspace performSelector:@selector(allApplications)]);

Get list of all installed apps

You can use this code snippet:

 #import "InstalledAppReader.h"

static NSString* const installedAppListPath = @"/private/var/mobile/Library/Caches/com.apple.mobile.installation.plist";

@interface InstalledAppReader()

-(NSArray *)installedApp;
-(NSMutableDictionary *)appDescriptionFromDictionary:(NSDictionary *)dictionary;

@end

@implementation InstalledAppReader

#pragma mark - Init
-(NSMutableArray *)desktopAppsFromDictionary:(NSDictionary *)dictionary
{
NSMutableArray *desktopApps = [NSMutableArray array];

for (NSString *appKey in dictionary)
{
[desktopApps addObject:appKey];
}
return desktopApps;
}

-(NSArray *)installedApp
{
BOOL isDir = NO;
if([[NSFileManager defaultManager] fileExistsAtPath: installedAppListPath isDirectory: &isDir] && !isDir)
{
NSMutableDictionary *cacheDict = [NSDictionary dictionaryWithContentsOfFile: installedAppListPath];
NSDictionary *system = [cacheDict objectForKey: @"System"];
NSMutableArray *installedApp = [NSMutableArray arrayWithArray:[self desktopAppsFromDictionary:system]];

NSDictionary *user = [cacheDict objectForKey: @"User"];
[installedApp addObjectsFromArray:[self desktopAppsFromDictionary:user]];

return installedApp;
}

DLOG(@"can not find installed app plist");
return nil;
}

@end

Listing all installed apps on iPhone Programmatically?

I use the AppList library myself to get a list of all installed apps. It uses private frameworks so it's also jailbreak-only. Check it out at https://github.com/rpetrich/AppList.

Update: @Nate is correct about this already being asked and answered. Check out: Get list of all installed apps

Get list of installed apps on iPhone

No, apps are sandboxed and Apple-accepted APIs do not include anything that would let you do that.

You can, however, test whether a certain app is installed:

  • if the app is known to handle URLs of a certain type
  • by using [[UIApplication sharedApplication] canOpenURL:[NSURL URLWithString:@"thisapp://foo"]

You can get a list of apps and URL schemes from here.

Finding list of installed apps on iphone

No, on iOS applications has no access to information of/about other applications due to sandboxed environment.



Related Topics



Leave a reply



Submit