-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathOTRestManagedObjectStore.h
More file actions
39 lines (32 loc) · 1.1 KB
/
OTRestManagedObjectStore.h
File metadata and controls
39 lines (32 loc) · 1.1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
//
// OTRestManagedObjectStore.h
// OTRestFramework
//
// Created by Blake Watters on 9/22/09.
// Copyright 2009 Two Toasters. All rights reserved.
//
#import <CoreData/CoreData.h>
@interface OTRestManagedObjectStore : NSObject {
NSString* _storeFilename;
NSManagedObjectModel* _managedObjectModel;
NSPersistentStoreCoordinator* _persistentStoreCoordinator;
NSManagedObjectContext* _managedObjectContext;
}
@property (nonatomic, readonly) NSString* storeFilename;
@property (nonatomic, readonly) NSManagedObjectModel *managedObjectModel;
@property (nonatomic, readonly) NSManagedObjectContext *managedObjectContext;
@property (nonatomic, readonly) NSPersistentStoreCoordinator *persistentStoreCoordinator;
/**
* Initialize a new managed object store with a SQLite database with the filename specified
*/
- (id)initWithStoreFilename:(NSString*)storeFilename;
/**
* Save the current contents of the managed object store
*/
- (NSError*)save;
/**
* This deletes and recreates the managed object context and
* persistant store, effectively clearing all data
*/
- (void)deletePersistantStore;
@end