Monotone-Parent: eb2ae1364da011cec8f9e025b9b53785ba2647d6

Monotone-Revision: fcec9822c0aaee8cefba77d0f50a8582b33fa3f0

Monotone-Author: wsourdeau@inverse.ca
Monotone-Date: 2012-07-10T16:02:16
Monotone-Branch: ca.inverse.sogo
This commit is contained in:
Wolfgang Sourdeau
2012-07-10 16:02:16 +00:00
parent a469952773
commit 961302407d
2 changed files with 89 additions and 0 deletions
+11
View File
@@ -1,5 +1,16 @@
2012-07-10 Wolfgang Sourdeau <wsourdeau@inverse.ca>
* SoObjects/Appointments/SOGoAppointmentFolder.m
(-davNotifyOnPersonalModifications)
(-setDavNotifyOnPersonalModifications:)
(-davNotifyOnExternalModifications)
(-setDavNotifyOnExternalModifications:)
(-davNotifyUserOnPersonalModifications)
(-setDavNotifyUserOnPersonalModifications:)
(-davNotifiedUserOnPersonalModifications)
(-setDavNotifiedUserOnPersonalModifications:): new dav accessors.
* SoObjects/SOGo/SOGoObject.m (-davBooleanForResult:): new method
that returns a valid DAV boolean from a BOOL.
(-isValidDAVBoolean:): new method that validates the value as a
@@ -2273,6 +2273,84 @@ firstInstanceCalendarDateRange: (NGCalendarDateRange *) fir
return error;
}
- (NSString *) davNotifyOnPersonalModifications
{
return [self davBooleanForResult: [self notifyOnPersonalModifications]];
}
- (NSException *) setDavNotifyOnPersonalModifications: (NSString *) newBoolean
{
NSException *error;
if ([self isValidDAVBoolean: newBoolean])
{
[self setNotifyOnPersonalModifications:
[self resultForDAVBoolean: newBoolean]];
error = nil;
}
else
error = [NSException exceptionWithHTTPStatus: 400
reason: @"Bad boolean value."];
return error;
}
- (NSString *) davNotifyOnExternalModifications
{
return [self davBooleanForResult: [self notifyOnExternalModifications]];
}
- (NSException *) setDavNotifyOnExternalModifications: (NSString *) newBoolean
{
NSException *error;
if ([self isValidDAVBoolean: newBoolean])
{
[self setNotifyOnExternalModifications:
[self resultForDAVBoolean: newBoolean]];
error = nil;
}
else
error = [NSException exceptionWithHTTPStatus: 400
reason: @"Bad boolean value."];
return error;
}
- (NSString *) davNotifyUserOnPersonalModifications
{
return [self davBooleanForResult: [self notifyUserOnPersonalModifications]];
}
- (NSException *) setDavNotifyUserOnPersonalModifications: (NSString *) newBoolean
{
NSException *error;
if ([self isValidDAVBoolean: newBoolean])
{
[self setNotifyUserOnPersonalModifications:
[self resultForDAVBoolean: newBoolean]];
error = nil;
}
else
error = [NSException exceptionWithHTTPStatus: 400
reason: @"Bad boolean value."];
return error;
}
- (NSString *) davNotifiedUserOnPersonalModifications
{
return [self notifiedUserOnPersonalModifications];
}
- (NSException *) setDavNotifiedUserOnPersonalModifications: (NSString *) theUser
{
[self setNotifiedUserOnPersonalModifications: theUser];
return nil;
}
/* vevent UID handling */
- (NSString *) resourceNameForEventUID: (NSString *) uid