Skip to content

robmaceachern/RMCoreDataStack

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

RMCoreDataStack

Version License Platform

Usage

In your own project

  1. Install via CocoaPods

    pod 'RMCoreDataStack'
    
  2. Import the public header

    #import <RMCoreDataStack/RMCoreDataStack.h>
    
  3. Setup your stack

    self.coreDataStack = [[RMCoreDataStack alloc] init];
    self.coreDataStack.delegate = self;
    [self.coreDataStack constructWithConfiguration:nil];
    
  4. Grab the NSManagedObject context and start persisting!

    NSManagedObjectContext context = self.coreDataStack.managedObjectContext;
    // pass context to your custom objects and view controllers
    

If you need to customize the configuration of the core data stack you can do so by creating an RMCoreDataConfiguration and passing it to the constructWithConfiguration: method.

Demo project

To run the example project, clone the repo, and run pod install from the Example directory first.

The BasicDemo is based on the XCode Master-Detail Application template. The only changes are in RMAppDelegate.

Requirements

The project is currently configured to support iOS 7 and higher. OSX is not currently supported but it will be soon.

Installation

RMCoreDataStack is available through CocoaPods. To install it, simply add the following line to your Podfile:

pod "RMCoreDataStack"

Author

Rob MacEachern, rob@robmaceachern.com

License

RMCoreDataStack is available under the MIT license. See the LICENSE file for more info.

About

Hit the ground running with a sane Core Data stack

Resources

License

Stars

Watchers

Forks

Packages

No packages published