Functions are not methods conceptually
Functions don't know about a self pointer because they typically don't belong to a class
In your case you have to make the function part of the class OR give it access to the class some other way (which wouldn't be OO style)
e.g.
@interface beDbAccess : NSObject
{
NSArray *path;
NSString *docPath;
NSString *dbPathString;
NSFileManager *fileManager;
}
@property (nonatomic, retain) NSArray *path;
@property (nonatomic) NSString *docPath;
@property (nonatomic) NSString *dbPathString;
@property (nonatomic) NSFileManager *fileManager;
#pragma functions callable from the outside
+ (id)sharedInstance;
-(NSString*)openDatabase;
#pragma functions
-(void)createNewDatabase;
@end
THEN use it from the outside like:
[[beDbAccess sharedInstance] openDatabase];