Directory of Ios-core data (XCODE6)

Source: Internet
Author: User

When using CoreData as the background data storage medium for the app, we would like to know if the data was successfully inserted. To do this, I want to find Coredata.sqlite's file.

The storage directory specified in the code is:

-(nsurl *) applicationdocumentsdirectory {

?

? ? return [[[Nsfilemanagerdefaultmanager] urlsfordirectory: Nsdocumentdirectoryindomains:nsuserdomainmask] lastobject];

}

So we would like to know whether there is really a file in this directory Coredata.sqlite, because after upgrading to XCode6 beta4, Apple modified the directory, IOS Simulator version also upgraded to 8.0, obviously the great user to the directory is not found:

User (current user)/library (Chinese: Resource library)/application Support/iphone simulator/

Under this directory I only found 6.1, user two folders, obviously not, then we can print the file address of the database in the program:

2014-08-13 19:40:00.199 sqlconnector[5876:863571] Store url:file:///users/admire/library/developer/coresimulator/ devices/d95c5e37-08c8-4929-8759-08bd284d9819/data/containers/data/application/ 9606a48c-0584-4bc4-a9a8-d8ac4f61cd0b/documents/datamodel.sqlite

Obviously this is the document we want to find;

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.