2 Copyright (C) 2000-2005 SKYRIX Software AG
4 This file is part of SOPE.
6 SOPE 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 SOPE 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 SOPE; see the file COPYING. If not, write to the
18 Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
23 #include "iCalRecurrenceRule.h"
26 @implementation iCalToDo
29 return [super version] + 0 /* v0 */;
32 NSAssert2([super version] == 0,
33 @"invalid superclass (%@) version %i !",
34 NSStringFromClass([self superclass]), [super version]);
39 [self->percentComplete release];
40 [self->completed release];
46 - (id)copyWithZone:(NSZone *)_zone {
49 new = [super copyWithZone:_zone];
51 new->due = [self->due copyWithZone:_zone];
52 new->percentComplete = [self->percentComplete copyWithZone:_zone];
53 new->completed = [self->completed copyWithZone:_zone];
60 - (void)setPercentComplete:(NSString *)_value {
61 ASSIGN(self->percentComplete, _value);
63 - (NSString *)percentComplete {
64 return self->percentComplete;
67 - (void)setDue:(NSCalendarDate *)_date {
68 ASSIGN(self->due, _date);
70 - (NSCalendarDate *)due {
74 - (void)setCompleted:(NSCalendarDate *)_date {
75 ASSIGN(self->completed, _date);
77 - (NSCalendarDate *)completed {
78 return self->completed;
83 - (NSString *)entityName {
89 - (NSString *)description {
92 ms = [NSMutableString stringWithCapacity:128];
93 [ms appendFormat:@"<0x%08X[%@]:", self, NSStringFromClass([self class])];
95 if (self->uid) [ms appendFormat:@" uid=%@", self->uid];
96 if (self->startDate) [ms appendFormat:@" start=%@", self->startDate];
97 if (self->due) [ms appendFormat:@" due=%@", self->due];
98 if (self->priority) [ms appendFormat:@" pri=%@", self->priority];
101 [ms appendFormat:@" completed=%@", self->completed];
102 if (self->percentComplete)
103 [ms appendFormat:@" complete=%@", self->percentComplete];
104 if (self->accessClass)
105 [ms appendFormat:@" class=%@", self->accessClass];
108 [ms appendFormat:@" summary=%@", self->summary];
110 [ms appendString:@">"];