Here's the error message:
warning: 'ReaderAppDelegate' may not respond to '-checkForDatabase' (Messages without a matching method signature will be assumed to return 'id' and accept '...' as arguments.
I put a breakpoint at the 'checkForDatabase' method in the code below, and it never got there... the app died. I'm assuming he warning above has something to do with the abort. How do I fix this? Do I have to declare 'checkForDatabase' in my .h file?
//--------------- application finished launching ----------------|
- (void)applicationDidFinishLaunching:(UIApplication *)application {
// create the d/b or get the connection value
[self checkForDatabase];
}
//-------------- check for database or create it ----------------|
- (void)checkForDatabase {
NSFileManager *filemanager = [NSFileManager defaultManager];
NSString *databasePath = [[NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES) objectAtIndex:0]
stringByAppendingString:@"/ppcipher.s3db"];
if(![filemanager fileExistsAtPath:databasePath]) { //Database doesn't exist yet, so we create it...
NSString *defaultDBPath = [[[NSBundle mainBundle] resourcePath] stringByAppendingString:@"/ppcipher.s3db"];
// remainder of code goes here...
}
}