Application of Bundles in iOS

Source: Internet
Author: User

The bundles in iOS are used to save resource files such as images, plist files, nib files, internationalized files, etc., according to their application to the bundle project under OS X [1] or target, bundle file.

Bundle project Creation references 1 and 2, using bundle engineering Note that you create a workspace before you create the main project, and then you create the bundle project. Document 1 Note Place 1: We need to modify Scheme:edit scheme-"build-" Add this bundle (click the + button in the lower left corner and select the bundle to join). Note 2: This bundle will be compiled automatically when other target is compiled, but the bundle will not be packaged in the app. "It's not necessary to use the bundle project, just use a simple bundle file," he thought. The bundle file deletes a file, and removes the file under the other folder in the project, and does not cause the entire bundle file to be updated. 】

We also need to add the run script to build parses (click the main project in the navigation bar and then click Targets-build Phases): Build phases-Add Run script (dot + sign)

The bundle file can change the suffix of a folder directly into a. Bundle and then drag it into the project, reference [3], or it can be created from the file-new-file-ios-resource-setting bundle path, reference [4].

Current bundle Project

As applications become more complex, sub-team and sub-engineering development becomes unavoidable, such as large-scale applications such as the US Regiment. If you need sub-engineering development, you can manage multiple projects under one workspace in iOS. You can also manage multiple target under one project without the need for sub-project development.

Reference documents:

1. iOS Engineering and resources files and bundles http://my.oschina.net/u/811205/blog/294278

2. ios-Generate Bundle Package-introduce bundle-use bundle http://blog.sina.com.cn/s/blog_7b9d64af0101jmj2.html

3.ios development using bundles to manage resource files

4. iOS8 correct access to Mainbundle and custom bundle sub-folder resource files NSBundle http://www.cocoachina.com/bbs/read.php?tid-319712.html

Application of Bundles in iOS

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.