2 Copyright (C) 2004-2005 SKYRIX Software AG
4 This file is part of OpenGroupware.org.
6 OGo is free software; you can redistribute it and/or modify it under
7 the terms of the GNU Lesser General Public License as published by the
8 Free Software Foundation; either version 2, or (at your option) any
11 OGo is distributed in the hope that it will be useful, but WITHOUT ANY
12 WARRANTY; without even the implied warranty of MERCHANTABILITY or
13 FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
14 License for more details.
16 You should have received a copy of the GNU Lesser General Public
17 License along with OGo; see the file COPYING. If not, write to the
18 Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
22 #ifndef __GDLContentStore_GCSFolderManager_H__
23 #define __GDLContentStore_GCSFolderManager_H__
25 #import <Foundation/NSObject.h>
30 Objects of this class manage the "folder_info" table, they manage the
31 model and manage the tables required for a folder.
34 @class NSString, NSArray, NSURL, NSDictionary, NSException;
35 @class GCSChannelManager, GCSFolder, GCSFolderType;
37 @interface GCSFolderManager : NSObject
39 GCSChannelManager *channelManager;
40 NSDictionary *nameToType;
41 NSURL *folderInfoLocation;
44 + (id)defaultFolderManager;
45 - (id)initWithFolderInfoLocation:(NSURL *)_url;
49 - (NSURL *)folderInfoLocation;
50 - (NSString *)folderInfoTableName;
54 - (GCSChannelManager *)channelManager;
57 /* handling folder names */
59 - (NSString *)internalNameFromPath:(NSString *)_path;
60 - (NSArray *)internalNamesFromPath:(NSString *)_path;
61 - (NSString *)pathFromInternalName:(NSString *)_name;
65 - (BOOL)folderExistsAtPath:(NSString *)_path;
66 - (NSArray *)listSubFoldersAtPath:(NSString *)_path recursive:(BOOL)_flag;
68 - (GCSFolder *)folderAtPath:(NSString *)_path;
70 - (NSException *)createFolderOfType:(NSString *)_type atPath:(NSString *)_path;
74 - (GCSFolderType *)folderTypeWithName:(NSString *)_name;
76 /* cache management */
82 #endif /* __GDLContentStore_GCSFolderManager_H__ */