]> err.no Git - scalable-opengroupware.org/blob - SOGo/SoObjects/Appointments/SOGoAppointmentFolder.h
added class versions to some files
[scalable-opengroupware.org] / SOGo / SoObjects / Appointments / SOGoAppointmentFolder.h
1 /*
2   Copyright (C) 2004-2005 SKYRIX Software AG
3
4   This file is part of OpenGroupware.org.
5
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
9   later version.
10
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.
15
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
19   02111-1307, USA.
20 */
21
22 #ifndef __Appointments_SOGoAppointmentFolder_H__
23 #define __Appointments_SOGoAppointmentFolder_H__
24
25 #include <SOGo/SOGoFolder.h>
26
27 /*
28   SOGoAppointmentFolder
29     Parent object: the SOGoUserFolder
30     Child objects: SOGoAppointmentObject
31     
32   The SOGoAppointmentFolder maps to an GCS folder of type 'appointment', that
33   is, a content folder containing iCalendar files (and a proper quicktable).
34   
35   Important:
36   The folder assumes a 1:1 mapping between the vevent UID field and the
37   resource name in the content store. In other words, you are not allowed to
38   create two different vevent-files with the same uid in the store.
39 */
40
41 @class NSString, NSArray, NSCalendarDate, NSException, NSMutableDictionary;
42 @class GCSFolder;
43
44 @interface SOGoAppointmentFolder : SOGoFolder
45 {
46   NSMutableDictionary *uidToFilename;
47 }
48
49 + (NSString *)globallyUniqueObjectId;
50
51 /* selection */
52
53 - (NSArray *)calendarUIDs;
54
55 /* vevent UID handling */
56
57 - (NSString *)resourceNameForEventUID:(NSString *)_uid;
58
59 /* fetching */
60
61 - (NSArray *)fetchFields:(NSArray *)_fields
62   fromFolder:(GCSFolder *)_folder
63   from:(NSCalendarDate *)_startDate
64   to:(NSCalendarDate *)_endDate;
65
66 - (NSArray *)fetchFields:(NSArray *)_fields
67   from:(NSCalendarDate *)_startDate
68   to:(NSCalendarDate *)_endDate;
69
70 - (NSArray *)fetchCoreInfosFrom:(NSCalendarDate *)_startDate
71   to:(NSCalendarDate *)_endDate;
72
73 - (NSArray *)fetchOverviewInfosFrom:(NSCalendarDate *)_startDate
74   to:(NSCalendarDate *)_endDate;
75
76 - (NSArray *)fetchFreebusyInfosFrom:(NSCalendarDate *)_startDate
77   to:(NSCalendarDate *)_endDate;
78
79 /* URL generation */
80
81 - (NSString *)baseURLForAptWithUID:(NSString *)_uid inContext:(id)_ctx;
82
83 /* folder management */
84
85 - (id)lookupHomeFolderForUID:(NSString *)_uid inContext:(id)_ctx;
86
87 - (NSArray *)lookupCalendarFoldersForUIDs:(NSArray *)_uids inContext:(id)_ctx;
88 - (NSArray *)lookupFreeBusyObjectsForUIDs:(NSArray *)_uids inContext:(id)_ctx;
89
90 - (NSArray *)uidsFromICalPersons:(NSArray *)_persons;
91 - (NSArray *)lookupCalendarFoldersForICalPerson:(NSArray *)_persons
92   inContext:(id)_ctx;
93
94 - (id)lookupGroupFolderForUIDs:(NSArray *)_uids         inContext:(id)_ctx;
95 - (id)lookupGroupCalendarFolderForUIDs:(NSArray *)_uids inContext:(id)_ctx;
96
97 /* bulk fetches */
98
99 - (NSArray *)fetchAllSOGoAppointments;
100
101 @end
102
103 #endif /* __Appointments_SOGoAppointmentFolder_H__ */