简体   繁体   English

如何在iPhone中的应用程序包之外访问文件

[英]How can I access files outside app bundle in iPhone

I want to create iPhone app that can play mp3 files that stored outside app bundle. 我想创建可以播放存储在应用程序包外部的mp3文件的iPhone应用程序。 The mp3 files that I want to access are stored in iPhone hard disk such as mp3 files that stored in iTunes_Control folder . 我要访问的mp3文件存储在iPhone硬盘中,例如iTunes_Control文件夹中存储的mp3文件

I want to retrieve these files from iTunes_Control folder in order to make a playlist and play them in my application without copy them into the application bundle. 我想从iTunes_Control文件夹中检索这些文件,以便制作一个播放列表并在我的应用程序中播放它们,而无需将它们复制到应用程序包中。 Do you have any idea how to solve this requirement? 您知道如何解决此要求吗?

Thank you very much. 非常感谢你。

Due to sandboxing you may only access files of your own app bundle. 由于使用沙箱,您只能访问自己的应用程序捆绑包中的文件。 As for the mp3files, You can access mp3 you stored with iTunes. 至于mp3文件,您可以访问与iTunes一起存储的mp3。 Check out this answer to find out how to do it. 查看此答案以了解如何操作。 Accessing users iTunes Library without MPMediaPickerController 在没有MPMediaPickerController的情况下访问用户iTunes Library

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM