获取捆绑包中定义的版权的infoDictionary密钥是什么?

mob*_*bob 6 iphone nsbundle ipad copyright-display

我想使用项目"info plist"捆绑中的版权.我找不到记录的密钥.有谁知道钥匙的价值?

[[[NSBundle mainBundle] infoDictionary] objectForKey: @"key-for-copyright"]
Run Code Online (Sandbox Code Playgroud)

Cod*_*aFi 10

它应该是NSHumanReadableCopyright.如果需要,您也可以对其进行本地化,但必须首先在plist中定义它.

如果对任何其他键感兴趣,请添加有用的建议:

NSLog(@"%s \n%@", __FUNCTION__, [[[NSBundle mainBundle] infoDictionary] allKeys]);
Run Code Online (Sandbox Code Playgroud)

产生如下结果:

2011-11-22 17:08:02.072 MyApp [1007:707] -[SplashScreenViewController viewWillAppear:] 
(
    CFBundleSignature,
    DTSDKName,
    DTPlatformBuild,
    BuildMachineOSBuild,
    NSBundleInitialPath,
    NSHumanReadableCopyright,
    CFBundleExecutable,
    CFBundleIconFiles,
    LSRequiresIPhoneOS,
    CFBundleInfoPlistURL,
    NSMainNibFile,
    CFBundleShortVersionString,
    CFBundlePackageType,
    NSBundleResolvedPath,
    DTSDKBuild,
    CFBundleResourceSpecification,
    DTXcodeBuild,
    DTCompiler,
    CFBundleDisplayName,
    CFBundleDevelopmentRegion,
    UTExportedTypeDeclarations,
    DTPlatformName,
    CFBundleURLTypes,
    CFBundleName,
    CFBundleVersion,
    UTImportedTypeDeclarations,
    CFBundleDocumentTypes,
    DTPlatformVersion,
    CFBundleSupportedPlatforms,
    DTXcode,
    MinimumOSVersion,
    UISupportedInterfaceOrientations,
    CFBundleIdentifier,
    UIAppFonts,
    UIDeviceFamily,
    CFBundleExecutablePath,
    CFBundleInfoDictionaryVersion
)
Run Code Online (Sandbox Code Playgroud)