to:(NSCalendarDate *)_endDate
{
#warning TODO: implement aggregation based on the container
+ NSArray *folders;
+
+ if ((folders = [[self container] valueForKey:@"memberFolders"]) == nil) {
+ [self logWithFormat:@"ERROR: calendar container has no 'memberFolders'?!"];
+ return nil;
+ }
+
return [NSArray array];
}
Child objects:
*/
+@class NSArray, NSDictionary;
+
@interface SOGoGroupFolder : SOGoObject
{
+ NSDictionary *uidToFolder;
+ NSArray *folders;
}
/* accessors */
- (NSArray *)uids;
+/* folder management */
+
+- (NSArray *)memberFolders;
+- (id)folderForUID:(NSString *)_uid;
+
+- (void)reset;
+
/* pathes */
@end
@implementation SOGoGroupFolder
- (void)dealloc {
+ [self->uidToFolder release];
[super dealloc];
}
return nil;
}
+/* folder management */
+
+- (id)_primaryLookupFolderForUID:(NSString *)_uid inContext:(id)_ctx {
+ NSException *error = nil;
+ NSArray *path;
+ id ctx, result;
+
+ /* create subcontext, so that we don't destroy our environment */
+
+ if ((ctx = [_ctx createSubContext]) == nil) {
+ [self logWithFormat:@"ERROR: could not create SOPE subcontext!"];
+ return nil;
+ }
+
+ /* build path */
+
+ path = [NSArray arrayWithObjects:&_uid count:1];
+
+ /* traverse path */
+
+ result = [[ctx application] traversePathArray:path inContext:ctx
+ error:&error acquire:NO];
+ if (error != nil) {
+ [self logWithFormat:@"ERROR: folder lookup failed (uid=%@): %@",
+ _uid, error];
+ return nil;
+ }
+
+ [self logWithFormat:@"Note: got folder for uid %@ path %@: %@",
+ _uid, [path componentsJoinedByString:@"=>"], result];
+ return result;
+}
+
+- (void)_setupFolders {
+ WOContext *ctx;
+ NSMutableDictionary *md;
+ NSMutableArray *ma;
+ NSArray *luids;
+ unsigned i, count;
+
+ if (self->uidToFolder != nil)
+ return;
+ if ((luids = [self uids]) == nil)
+ return;
+
+ ctx = [[WOApplication application] context];
+
+ count = [luids count];
+ ma = [NSMutableArray arrayWithCapacity:count + 1];
+ md = [NSMutableDictionary dictionaryWithCapacity:count];
+
+ for (i = 0; i < count; i++) {
+ NSString *uid;
+ id folder;
+
+ uid = [luids objectAtIndex:i];
+ folder = [self _primaryLookupFolderForUID:uid inContext:ctx];
+
+ if ([folder isNotNull]) {
+ [md setObject:folder forKey:uid];
+ [ma addObject:folder];
+ }
+ else
+ [ma addObject:[NSNull null]];
+ }
+
+ /* fix results */
+ self->uidToFolder = [md copy];
+ self->folders = [[NSArray alloc] initWithArray:ma];
+}
+
+- (NSArray *)memberFolders {
+ [self _setupFolders];
+ return self->folders;
+}
+
+- (id)folderForUID:(NSString *)_uid {
+ [self _setupFolders];
+
+ if ([_uid length] == 0)
+ return nil;
+
+ return [self->uidToFolder objectForKey:_uid];
+}
+
+- (void)reset {
+ [self->uidToFolder release]; self->uidToFolder = nil;
+ [self->folders release]; self->folders = nil;
+}
+
/* SOPE */
- (BOOL)isFolderish {
/*
- Copyright (C) 2000-2004 SKYRIX Software AG
+ Copyright (C) 2004 SKYRIX Software AG
This file is part of OpenGroupware.org.
/*
- Copyright (C) 2000-2004 SKYRIX Software AG
+ Copyright (C) 2004 SKYRIX Software AG
This file is part of OpenGroupware.org.
/*
- Copyright (C) 2000-2004 SKYRIX Software AG
+ Copyright (C) 2004 SKYRIX Software AG
This file is part of OpenGroupware.org.
/*
- Copyright (C) 2000-2004 SKYRIX Software AG
+ Copyright (C) 2004 SKYRIX Software AG
- This file is part of OGo
+ This file is part of OpenGroupware.org.
OGo is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
/*
- Copyright (C) 2000-2004 SKYRIX Software AG
+ Copyright (C) 2004 SKYRIX Software AG
This file is part of OGo
/*
- Copyright (C) 2000-2004 SKYRIX Software AG
+ Copyright (C) 2004 SKYRIX Software AG
- This file is part of OGo
+ This file is part of OpenGroupware.org.
OGo is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
/*
- Copyright (C) 2000-2004 SKYRIX Software AG
+ Copyright (C) 2004 SKYRIX Software AG
- This file is part of OGo
+ This file is part of OpenGroupware.org.
OGo is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
/*
- Copyright (C) 2000-2004 SKYRIX Software AG
+ Copyright (C) 2004 SKYRIX Software AG
- This file is part of OGo
+ This file is part of OpenGroupware.org.
OGo is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
/*
- Copyright (C) 2000-2004 SKYRIX Software AG
+ Copyright (C) 2004 SKYRIX Software AG
- This file is part of OGo
+ This file is part of OpenGroupware.org.
OGo is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
/*
- Copyright (C) 2000-2004 SKYRIX Software AG
+ Copyright (C) 2004 SKYRIX Software AG
- This file is part of OGo
+ This file is part of OpenGroupware.org.
OGo is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
/*
- Copyright (C) 2000-2004 SKYRIX Software AG
+ Copyright (C) 2004 SKYRIX Software AG
- This file is part of OGo
+ This file is part of OpenGroupware.org.
OGo is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
/*
- Copyright (C) 2000-2004 SKYRIX Software AG
+ Copyright (C) 2004 SKYRIX Software AG
- This file is part of OGo
+ This file is part of OpenGroupware.org.
OGo is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
/*
- Copyright (C) 2000-2004 SKYRIX Software AG
+ Copyright (C) 2004 SKYRIX Software AG
- This file is part of OGo
+ This file is part of OpenGroupware.org.
OGo is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
/*
- Copyright (C) 2000-2004 SKYRIX Software AG
+ Copyright (C) 2004 SKYRIX Software AG
- This file is part of OGo
+ This file is part of OpenGroupware.org.
OGo is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
/*
- Copyright (C) 2000-2004 SKYRIX Software AG
+ Copyright (C) 2004 SKYRIX Software AG
- This file is part of OGo
+ This file is part of OpenGroupware.org.
OGo is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
/*
- Copyright (C) 2000-2004 SKYRIX Software AG
+ Copyright (C) 2004 SKYRIX Software AG
- This file is part of OGo
+ This file is part of OpenGroupware.org.
OGo is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
/*
- Copyright (C) 2000-2004 SKYRIX Software AG
+ Copyright (C) 2004 SKYRIX Software AG
- This file is part of OGo
+ This file is part of OpenGroupware.org.
OGo is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
/*
- Copyright (C) 2000-2004 SKYRIX Software AG
+ Copyright (C) 2004 SKYRIX Software AG
- This file is part of OGo
+ This file is part of OpenGroupware.org.
OGo is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
*/
// $Id$
-
#include "UIxCalWeekView.h"
-#include "common.h"
@interface UIxCalWeekListview : UIxCalWeekView
{
-
}
@end
+#include "common.h"
@implementation UIxCalWeekListview
-
-@end
+@end /* UIxCalWeekListview */
title="name">
<!-- $Id: SkyNews.html,v 1.3 2003/12/22 16:53:55 helge Exp $ -->
- <table id="skywintable" class="wintable" cellspacing="0" cellpadding="5" width="100%">
+ <table id="skywintable" class="wintable"
+ cellspacing="0" cellpadding="5" width="100%">
<tr>
<td class="wintitle">
<table cellpadding="0" cellspacing="0" width="100%">
<tr>
<td width="5"/>
- <td class="wintitle"><var:component className="UIxCalDateLabel" startDate="startDate" endDate="endDate" const:selection="week" /></td>
+ <td class="wintitle"><var:component className="UIxCalDateLabel"
+ startDate="startDate" endDate="endDate"
+ const:selection="week" /></td>
<td width="36" align="right" valign="center">
<var:component className="UIxWinClose" />
</td>
/*
- Copyright (C) 2000-2004 SKYRIX Software AG
+ Copyright (C) 2004 SKYRIX Software AG
- This file is part of OpenGroupware.org.
+ This file is part of OpenGroupware.org.
- OGo is free software; you can redistribute it and/or modify it under
- the terms of the GNU Lesser General Public License as published by the
- Free Software Foundation; either version 2, or (at your option) any
- later version.
+ OGo is free software; you can redistribute it and/or modify it under
+ the terms of the GNU Lesser General Public License as published by the
+ Free Software Foundation; either version 2, or (at your option) any
+ later version.
- OGo is distributed in the hope that it will be useful, but WITHOUT ANY
- WARRANTY; without even the implied warranty of MERCHANTABILITY or
- FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
- License for more details.
+ OGo is distributed in the hope that it will be useful, but WITHOUT ANY
+ WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+ License for more details.
- You should have received a copy of the GNU Lesser General Public
- License along with OGo; see the file COPYING. If not, write to the
- Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
- 02111-1307, USA.
- */
+ You should have received a copy of the GNU Lesser General Public
+ License along with OGo; see the file COPYING. If not, write to the
+ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA.
+*/
// $Id$
#include "UIxCalWeekView.h"
/*
- Copyright (C) 2000-2004 SKYRIX Software AG
+ Copyright (C) 2004 SKYRIX Software AG
This file is part of OpenGroupware.org.
/*
- Copyright (C) 2000-2004 SKYRIX Software AG
+ Copyright (C) 2004 SKYRIX Software AG
- This file is part of OGo
+ This file is part of OpenGroupware.org.
OGo is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
/*
- Copyright (C) 2000-2004 SKYRIX Software AG
+ Copyright (C) 2004 SKYRIX Software AG
- This file is part of OGo
+ This file is part of OpenGroupware.org.
OGo is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
/*
- Copyright (C) 2000-2004 SKYRIX Software AG
+ Copyright (C) 2004 SKYRIX Software AG
This file is part of OpenGroupware.org.
Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
02111-1307, USA.
*/
-// $Id: common.h,v 1.1 2003/11/24 01:24:40 helge Exp $
+// $Id$
#import <Foundation/Foundation.h>