Monotone-Parent: a4b72920f072cccd72e189b05519b57436eb9471
Monotone-Revision: 71372fb23c7baec6da2c9bd612ed5a65db22f208 Monotone-Author: wsourdeau@inverse.ca Monotone-Date: 2010-04-21T14:35:58 Monotone-Branch: ca.inverse.sogomaint-2.0.2
parent
28911e16dd
commit
f51c2b0f5b
|
@ -1,3 +1,8 @@
|
|||
2010-04-21 Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
|
||||
* Main/SOGo+DAV.m: commented out incomplete code for handling
|
||||
DAV:principal-property-search
|
||||
|
||||
2010-04-20 Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
|
||||
* SoObjects/SOGo/SOGoUser.m (-mailAccounts): use the user's first
|
||||
|
|
|
@ -31,7 +31,7 @@
|
|||
@interface SOGo (SOGoWebDAVExtensions)
|
||||
|
||||
- (WOResponse *) davPrincipalMatch: (WOContext *) localContext;
|
||||
- (WOResponse *) davPrincipalPropertySearch: (WOContext *) localContext;
|
||||
// - (WOResponse *) davPrincipalPropertySearch: (WOContext *) localContext;
|
||||
- (WOResponse *) davPrincipalSearchPropertySet: (WOContext *) localContext;
|
||||
|
||||
@end
|
||||
|
|
448
Main/SOGo+DAV.m
448
Main/SOGo+DAV.m
|
@ -21,9 +21,11 @@
|
|||
*/
|
||||
|
||||
#import <Foundation/NSDictionary.h>
|
||||
#import <Foundation/NSEnumerator.h>
|
||||
|
||||
#import <NGObjWeb/NSException+HTTP.h>
|
||||
#import <NGObjWeb/WOContext+SoObjects.h>
|
||||
#import <NGObjWeb/WORequest.h>
|
||||
#import <NGExtensions/NSObject+Logs.h>
|
||||
|
||||
#import <DOM/DOMDocument.h>
|
||||
|
@ -38,6 +40,7 @@
|
|||
#import <SOGo/WOResponse+SOGo.h>
|
||||
#import <SOGo/SOGoPermissions.h>
|
||||
#import <SOGo/SOGoUser.h>
|
||||
#import <SOGo/SOGoUserFolder.h>
|
||||
|
||||
#import "SOGo+DAV.h"
|
||||
|
||||
|
@ -235,165 +238,165 @@
|
|||
return r;
|
||||
}
|
||||
|
||||
- (void) _fillMatches: (NSMutableDictionary *) matches
|
||||
fromElement: (NSObject <DOMElement> *) searchElement
|
||||
{
|
||||
NSObject <DOMNodeList> *list;
|
||||
NSObject <DOMNode> *valueNode;
|
||||
NSArray *elements;
|
||||
NSString *property, *match;
|
||||
// - (void) _fillMatches: (NSMutableDictionary *) matches
|
||||
// fromElement: (NSObject <DOMElement> *) searchElement
|
||||
// {
|
||||
// NSObject <DOMNodeList> *list;
|
||||
// NSObject <DOMNode> *valueNode;
|
||||
// NSArray *elements;
|
||||
// NSString *property, *match;
|
||||
|
||||
list = [searchElement getElementsByTagName: @"prop"];
|
||||
if ([list length])
|
||||
{
|
||||
elements = [self domNode: [list objectAtIndex: 0]
|
||||
getChildNodesByType: DOM_ELEMENT_NODE];
|
||||
if ([elements count])
|
||||
{
|
||||
valueNode = [elements objectAtIndex: 0];
|
||||
property = [NSString stringWithFormat: @"{%@}%@",
|
||||
[valueNode namespaceURI],
|
||||
[valueNode nodeName]];
|
||||
}
|
||||
}
|
||||
list = [searchElement getElementsByTagName: @"match"];
|
||||
if ([list length])
|
||||
{
|
||||
valueNode = [[list objectAtIndex: 0] firstChild];
|
||||
match = [valueNode nodeValue];
|
||||
}
|
||||
// list = [searchElement getElementsByTagName: @"prop"];
|
||||
// if ([list length])
|
||||
// {
|
||||
// elements = [self domNode: [list objectAtIndex: 0]
|
||||
// getChildNodesByType: DOM_ELEMENT_NODE];
|
||||
// if ([elements count])
|
||||
// {
|
||||
// valueNode = [elements objectAtIndex: 0];
|
||||
// property = [NSString stringWithFormat: @"{%@}%@",
|
||||
// [valueNode namespaceURI],
|
||||
// [valueNode nodeName]];
|
||||
// }
|
||||
// }
|
||||
// list = [searchElement getElementsByTagName: @"match"];
|
||||
// if ([list length])
|
||||
// {
|
||||
// valueNode = [[list objectAtIndex: 0] firstChild];
|
||||
// match = [valueNode nodeValue];
|
||||
// }
|
||||
|
||||
[matches setObject: match forKey: property];
|
||||
}
|
||||
// [matches setObject: match forKey: property];
|
||||
// }
|
||||
|
||||
- (void) _fillProperties: (NSMutableArray *) properties
|
||||
fromElement: (NSObject <DOMElement> *) propElement
|
||||
{
|
||||
NSEnumerator *elements;
|
||||
NSObject <DOMElement> *propNode;
|
||||
NSString *property;
|
||||
// - (void) _fillProperties: (NSMutableArray *) properties
|
||||
// fromElement: (NSObject <DOMElement> *) propElement
|
||||
// {
|
||||
// NSEnumerator *elements;
|
||||
// NSObject <DOMElement> *propNode;
|
||||
// NSString *property;
|
||||
|
||||
elements = [[self domNode: propElement
|
||||
getChildNodesByType: DOM_ELEMENT_NODE]
|
||||
objectEnumerator];
|
||||
while ((propNode = [elements nextObject]))
|
||||
{
|
||||
property = [NSString stringWithFormat: @"{%@}%@",
|
||||
[propNode namespaceURI],
|
||||
[propNode nodeName]];
|
||||
[properties addObject: property];
|
||||
}
|
||||
}
|
||||
// elements = [[self domNode: propElement
|
||||
// getChildNodesByType: DOM_ELEMENT_NODE]
|
||||
// objectEnumerator];
|
||||
// while ((propNode = [elements nextObject]))
|
||||
// {
|
||||
// property = [NSString stringWithFormat: @"{%@}%@",
|
||||
// [propNode namespaceURI],
|
||||
// [propNode nodeName]];
|
||||
// [properties addObject: property];
|
||||
// }
|
||||
// }
|
||||
|
||||
- (void) _fillPrincipalMatches: (NSMutableDictionary *) matches
|
||||
andProperties: (NSMutableArray *) properties
|
||||
fromElement: (NSObject <DOMElement> *) documentElement
|
||||
{
|
||||
NSEnumerator *children;
|
||||
NSObject <DOMElement> *currentElement;
|
||||
NSString *tag;
|
||||
// - (void) _fillPrincipalMatches: (NSMutableDictionary *) matches
|
||||
// andProperties: (NSMutableArray *) properties
|
||||
// fromElement: (NSObject <DOMElement> *) documentElement
|
||||
// {
|
||||
// NSEnumerator *children;
|
||||
// NSObject <DOMElement> *currentElement;
|
||||
// NSString *tag;
|
||||
|
||||
children = [[self domNode: documentElement
|
||||
getChildNodesByType: DOM_ELEMENT_NODE]
|
||||
objectEnumerator];
|
||||
while ((currentElement = [children nextObject]))
|
||||
{
|
||||
tag = [currentElement tagName];
|
||||
if ([tag isEqualToString: @"property-search"])
|
||||
[self _fillMatches: matches fromElement: currentElement];
|
||||
else if ([tag isEqualToString: @"prop"])
|
||||
[self _fillProperties: properties fromElement: currentElement];
|
||||
else
|
||||
[self errorWithFormat: @"principal-property-search: unknown tag '%@'",
|
||||
tag];
|
||||
}
|
||||
}
|
||||
// children = [[self domNode: documentElement
|
||||
// getChildNodesByType: DOM_ELEMENT_NODE]
|
||||
// objectEnumerator];
|
||||
// while ((currentElement = [children nextObject]))
|
||||
// {
|
||||
// tag = [currentElement tagName];
|
||||
// if ([tag isEqualToString: @"property-search"])
|
||||
// [self _fillMatches: matches fromElement: currentElement];
|
||||
// else if ([tag isEqualToString: @"prop"])
|
||||
// [self _fillProperties: properties fromElement: currentElement];
|
||||
// else
|
||||
// [self errorWithFormat: @"principal-property-search: unknown tag '%@'",
|
||||
// tag];
|
||||
// }
|
||||
// }
|
||||
|
||||
#warning this is a bit ugly, as usual
|
||||
- (void) _fillCollections: (NSMutableArray *) collections
|
||||
withCalendarHomeSetMatching: (NSString *) value
|
||||
inContext: (WOContext *) localContext
|
||||
{
|
||||
SOGoUserFolder *collection;
|
||||
NSRange substringRange;
|
||||
// - (void) _fillCollections: (NSMutableArray *) collections
|
||||
// withCalendarHomeSetMatching: (NSString *) value
|
||||
// inContext: (WOContext *) localContext
|
||||
// {
|
||||
// SOGoUserFolder *collection;
|
||||
// NSRange substringRange;
|
||||
|
||||
substringRange = [value rangeOfString: @"/SOGo/dav/"];
|
||||
value = [value substringFromIndex: NSMaxRange (substringRange)];
|
||||
substringRange = [value rangeOfString: @"/Calendar"];
|
||||
value = [value substringToIndex: substringRange.location];
|
||||
collection = [[SOGoUser userWithLogin: value]
|
||||
homeFolderInContext: localContext];
|
||||
if (collection)
|
||||
[collections addObject: collection];
|
||||
}
|
||||
// substringRange = [value rangeOfString: @"/SOGo/dav/"];
|
||||
// value = [value substringFromIndex: NSMaxRange (substringRange)];
|
||||
// substringRange = [value rangeOfString: @"/Calendar"];
|
||||
// value = [value substringToIndex: substringRange.location];
|
||||
// collection = [[SOGoUser userWithLogin: value]
|
||||
// homeFolderInContext: localContext];
|
||||
// if (collection)
|
||||
// [collections addObject: collection];
|
||||
// }
|
||||
|
||||
- (NSMutableArray *) _firstPrincipalCollectionsWhere: (NSString *) key
|
||||
matches: (NSString *) value
|
||||
inContext: (WOContext *) localContext
|
||||
{
|
||||
NSMutableArray *collections;
|
||||
// - (NSMutableArray *) _firstPrincipalCollectionsWhere: (NSString *) key
|
||||
// matches: (NSString *) value
|
||||
// inContext: (WOContext *) localContext
|
||||
// {
|
||||
// NSMutableArray *collections;
|
||||
|
||||
collections = [NSMutableArray array];
|
||||
if ([key
|
||||
isEqualToString: @"{urn:ietf:params:xml:ns:caldav}calendar-home-set"])
|
||||
[self _fillCollections: collections withCalendarHomeSetMatching: value
|
||||
inContext: localContext];
|
||||
else
|
||||
[self errorWithFormat: @"principal-property-search: unhandled key '%@'",
|
||||
key];
|
||||
// collections = [NSMutableArray array];
|
||||
// if ([key
|
||||
// isEqualToString: @"{urn:ietf:params:xml:ns:caldav}calendar-home-set"])
|
||||
// [self _fillCollections: collections withCalendarHomeSetMatching: value
|
||||
// inContext: localContext];
|
||||
// else
|
||||
// [self errorWithFormat: @"principal-property-search: unhandled key '%@'",
|
||||
// key];
|
||||
|
||||
return collections;
|
||||
}
|
||||
// return collections;
|
||||
// }
|
||||
|
||||
#warning unused stub
|
||||
- (BOOL) collectionDavKey: (NSString *) key
|
||||
matches: (NSString *) value
|
||||
{
|
||||
return YES;
|
||||
}
|
||||
// #warning unused stub
|
||||
// - (BOOL) collectionDavKey: (NSString *) key
|
||||
// matches: (NSString *) value
|
||||
// {
|
||||
// return YES;
|
||||
// }
|
||||
|
||||
- (void) _principalCollections: (NSMutableArray **) baseCollections
|
||||
where: (NSString *) key
|
||||
matches: (NSString *) value
|
||||
inContext: (WOContext *) localContext
|
||||
{
|
||||
SOGoUserFolder *currentCollection;
|
||||
unsigned int count, max;
|
||||
// - (void) _principalCollections: (NSMutableArray **) baseCollections
|
||||
// where: (NSString *) key
|
||||
// matches: (NSString *) value
|
||||
// inContext: (WOContext *) localContext
|
||||
// {
|
||||
// SOGoUserFolder *currentCollection;
|
||||
// unsigned int count, max;
|
||||
|
||||
if (!*baseCollections)
|
||||
*baseCollections = [self _firstPrincipalCollectionsWhere: key
|
||||
matches: value
|
||||
inContext: localContext];
|
||||
else
|
||||
{
|
||||
max = [*baseCollections count];
|
||||
for (count = max; count > 0; count--)
|
||||
{
|
||||
currentCollection = [*baseCollections objectAtIndex: count - 1];
|
||||
if (![currentCollection collectionDavKey: key matches: value])
|
||||
[*baseCollections removeObjectAtIndex: count - 1];
|
||||
}
|
||||
}
|
||||
}
|
||||
// if (!*baseCollections)
|
||||
// *baseCollections = [self _firstPrincipalCollectionsWhere: key
|
||||
// matches: value
|
||||
// inContext: localContext];
|
||||
// else
|
||||
// {
|
||||
// max = [*baseCollections count];
|
||||
// for (count = max; count > 0; count--)
|
||||
// {
|
||||
// currentCollection = [*baseCollections objectAtIndex: count - 1];
|
||||
// if (![currentCollection collectionDavKey: key matches: value])
|
||||
// [*baseCollections removeObjectAtIndex: count - 1];
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
|
||||
- (NSArray *) _principalCollectionsMatching: (NSDictionary *) matches
|
||||
inContext: (WOContext *) localContext
|
||||
{
|
||||
NSMutableArray *collections;
|
||||
NSEnumerator *allKeys;
|
||||
NSString *currentKey;
|
||||
// - (NSArray *) _principalCollectionsMatching: (NSDictionary *) matches
|
||||
// inContext: (WOContext *) localContext
|
||||
// {
|
||||
// NSMutableArray *collections;
|
||||
// NSEnumerator *allKeys;
|
||||
// NSString *currentKey;
|
||||
|
||||
collections = nil;
|
||||
// collections = nil;
|
||||
|
||||
allKeys = [[matches allKeys] objectEnumerator];
|
||||
while ((currentKey = [allKeys nextObject]))
|
||||
[self _principalCollections: &collections
|
||||
where: currentKey
|
||||
matches: [matches objectForKey: currentKey]
|
||||
inContext: localContext];
|
||||
// allKeys = [[matches allKeys] objectEnumerator];
|
||||
// while ((currentKey = [allKeys nextObject]))
|
||||
// [self _principalCollections: &collections
|
||||
// where: currentKey
|
||||
// matches: [matches objectForKey: currentKey]
|
||||
// inContext: localContext];
|
||||
|
||||
return collections;
|
||||
}
|
||||
// return collections;
|
||||
// }
|
||||
|
||||
/* <D:principal-property-search xmlns:D="DAV:">
|
||||
<D:property-search>
|
||||
|
@ -417,97 +420,96 @@
|
|||
</D:prop>
|
||||
</D:principal-property-search> */
|
||||
|
||||
- (void) _appendProperties: (NSArray *) properties
|
||||
ofCollection: (SOGoUserFolder *) collection
|
||||
toResponses: (NSMutableArray *) responses
|
||||
{
|
||||
unsigned int count, max;
|
||||
SEL methodSel;
|
||||
NSString *currentProperty;
|
||||
id currentValue;
|
||||
NSMutableArray *response, *props;
|
||||
NSDictionary *keyTuple;
|
||||
// - (void) _appendProperties: (NSArray *) properties
|
||||
// ofCollection: (SOGoUserFolder *) collection
|
||||
// toResponses: (NSMutableArray *) responses
|
||||
// {
|
||||
// unsigned int count, max;
|
||||
// SEL methodSel;
|
||||
// NSString *currentProperty;
|
||||
// id currentValue;
|
||||
// NSMutableArray *response, *props;
|
||||
// NSDictionary *keyTuple;
|
||||
|
||||
response = [NSMutableArray array];
|
||||
[response addObject: davElementWithContent (@"href", XMLNS_WEBDAV,
|
||||
[collection davURLAsString])];
|
||||
props = [NSMutableArray array];
|
||||
max = [properties count];
|
||||
for (count = 0; count < max; count++)
|
||||
{
|
||||
currentProperty = [properties objectAtIndex: count];
|
||||
methodSel = SOGoSelectorForPropertyGetter (currentProperty);
|
||||
if (methodSel && [collection respondsToSelector: methodSel])
|
||||
{
|
||||
currentValue = [collection performSelector: methodSel];
|
||||
#warning evil eVIL EVIl!
|
||||
if ([currentValue isKindOfClass: [NSArray class]])
|
||||
{
|
||||
currentValue = [currentValue objectAtIndex: 0];
|
||||
currentValue
|
||||
= davElementWithContent ([currentValue objectAtIndex: 0],
|
||||
[currentValue objectAtIndex: 1],
|
||||
[currentValue objectAtIndex: 3]);
|
||||
}
|
||||
keyTuple = [currentProperty asWebDAVTuple];
|
||||
[props addObject: davElementWithContent ([keyTuple objectForKey: @"method"],
|
||||
[keyTuple objectForKey: @"ns"],
|
||||
currentValue)];
|
||||
}
|
||||
}
|
||||
[response addObject: davElementWithContent (@"propstat", XMLNS_WEBDAV,
|
||||
davElementWithContent
|
||||
(@"prop", XMLNS_WEBDAV,
|
||||
props))];
|
||||
[responses addObject: davElementWithContent (@"response", XMLNS_WEBDAV,
|
||||
response)];
|
||||
}
|
||||
// response = [NSMutableArray array];
|
||||
// [response addObject: davElementWithContent (@"href", XMLNS_WEBDAV,
|
||||
// [collection davURLAsString])];
|
||||
// props = [NSMutableArray array];
|
||||
// max = [properties count];
|
||||
// for (count = 0; count < max; count++)
|
||||
// {
|
||||
// currentProperty = [properties objectAtIndex: count];
|
||||
// methodSel = SOGoSelectorForPropertyGetter (currentProperty);
|
||||
// if (methodSel && [collection respondsToSelector: methodSel])
|
||||
// {
|
||||
// currentValue = [collection performSelector: methodSel];
|
||||
// #warning evil eVIL EVIl!
|
||||
// if ([currentValue isKindOfClass: [NSArray class]])
|
||||
// {
|
||||
// currentValue = [currentValue objectAtIndex: 0];
|
||||
// currentValue
|
||||
// = davElementWithContent ([currentValue objectAtIndex: 0],
|
||||
// [currentValue objectAtIndex: 1],
|
||||
// [currentValue objectAtIndex: 3]);
|
||||
// }
|
||||
// keyTuple = [currentProperty asWebDAVTuple];
|
||||
// [props addObject: davElementWithContent ([keyTuple objectForKey: @"method"],
|
||||
// [keyTuple objectForKey: @"ns"],
|
||||
// currentValue)];
|
||||
// }
|
||||
// }
|
||||
// [response addObject: davElementWithContent (@"propstat", XMLNS_WEBDAV,
|
||||
// davElementWithContent
|
||||
// (@"prop", XMLNS_WEBDAV,
|
||||
// props))];
|
||||
// [responses addObject: davElementWithContent (@"response", XMLNS_WEBDAV,
|
||||
// response)];
|
||||
// }
|
||||
|
||||
- (void) _appendProperties: (NSArray *) properties
|
||||
ofCollections: (NSArray *) collections
|
||||
toResponse: (WOResponse *) response
|
||||
{
|
||||
NSDictionary *mStatus;
|
||||
NSMutableArray *responses;
|
||||
unsigned int count, max;
|
||||
// - (void) _appendProperties: (NSArray *) properties
|
||||
// ofCollections: (NSArray *) collections
|
||||
// toResponse: (WOResponse *) response
|
||||
// {
|
||||
// NSDictionary *mStatus;
|
||||
// NSMutableArray *responses;
|
||||
// unsigned int count, max;
|
||||
|
||||
max = [collections count];
|
||||
responses = [NSMutableArray arrayWithCapacity: max];
|
||||
for (count = 0; count < max; count++)
|
||||
[self _appendProperties: properties
|
||||
ofCollection: [collections objectAtIndex: count]
|
||||
toResponses: responses];
|
||||
mStatus = davElementWithContent (@"multistatus", XMLNS_WEBDAV, responses);
|
||||
[response appendContentString: [mStatus asWebDavStringWithNamespaces: nil]];
|
||||
}
|
||||
// max = [collections count];
|
||||
// responses = [NSMutableArray arrayWithCapacity: max];
|
||||
// for (count = 0; count < max; count++)
|
||||
// [self _appendProperties: properties
|
||||
// ofCollection: [collections objectAtIndex: count]
|
||||
// toResponses: responses];
|
||||
// mStatus = davElementWithContent (@"multistatus", XMLNS_WEBDAV, responses);
|
||||
// [response appendContentString: [mStatus asWebDavStringWithNamespaces: nil]];
|
||||
// }
|
||||
|
||||
/* rfc3744, should be moved into SOGoUserFolder */
|
||||
- (WOResponse *) davPrincipalPropertySearch: (WOContext *) localContext
|
||||
{
|
||||
NSObject <DOMDocument> *document;
|
||||
NSObject <DOMElement> *documentElement;
|
||||
NSArray *collections;
|
||||
NSMutableDictionary *matches;
|
||||
NSMutableArray *properties;
|
||||
WOResponse *r;
|
||||
|
||||
document = [[localContext request] contentAsDOMDocument];
|
||||
documentElement = [document documentElement];
|
||||
// - (WOResponse *) davPrincipalPropertySearch: (WOContext *) localContext
|
||||
// {
|
||||
// NSObject <DOMDocument> *document;
|
||||
// NSObject <DOMElement> *documentElement;
|
||||
// NSArray *collections;
|
||||
// NSMutableDictionary *matches;
|
||||
// NSMutableArray *properties;
|
||||
// WOResponse *r;
|
||||
|
||||
matches = [NSMutableDictionary dictionary];
|
||||
properties = [NSMutableArray array];
|
||||
[self _fillPrincipalMatches: matches andProperties: properties
|
||||
fromElement: documentElement];
|
||||
collections = [self _principalCollectionsMatching: matches
|
||||
inContext: localContext];
|
||||
r = [localContext response];
|
||||
[r prepareDAVResponse];
|
||||
[self _appendProperties: properties ofCollections: collections
|
||||
toResponse: r];
|
||||
|
||||
return r;
|
||||
}
|
||||
// document = [[localContext request] contentAsDOMDocument];
|
||||
// documentElement = [document documentElement];
|
||||
|
||||
// matches = [NSMutableDictionary dictionary];
|
||||
// properties = [NSMutableArray array];
|
||||
// [self _fillPrincipalMatches: matches andProperties: properties
|
||||
// fromElement: documentElement];
|
||||
// collections = [self _principalCollectionsMatching: matches
|
||||
// inContext: localContext];
|
||||
// r = [localContext response];
|
||||
// [r prepareDAVResponse];
|
||||
// [self _appendProperties: properties ofCollections: collections
|
||||
// toResponse: r];
|
||||
|
||||
// return r;
|
||||
// }
|
||||
|
||||
@end
|
||||
|
|
|
@ -69,7 +69,7 @@
|
|||
#import <SOGo/WORequest+SOGo.h>
|
||||
#import <SOGo/WOResponse+SOGo.h>
|
||||
|
||||
#import "iCalEntityObject+SOGo.h"
|
||||
#import "iCalRepeatableEntityObject+SOGo.h"
|
||||
#import "iCalPerson+SOGo.h"
|
||||
#import "SOGoAppointmentObject.h"
|
||||
#import "SOGoAppointmentFolders.h"
|
||||
|
|
|
@ -21,6 +21,7 @@
|
|||
*/
|
||||
|
||||
#import <Foundation/NSArray.h>
|
||||
#import <Foundation/NSEnumerator.h>
|
||||
#import <Foundation/NSException.h>
|
||||
#import <Foundation/NSString.h>
|
||||
#import <SaxObjC/XMLNamespaces.h>
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
#import <Foundation/NSDictionary.h>
|
||||
#import <Foundation/NSEnumerator.h>
|
||||
#import <Foundation/NSTimeZone.h>
|
||||
#import <Foundation/NSValue.h>
|
||||
|
||||
#import <NGObjWeb/NSException+HTTP.h>
|
||||
#import <NGObjWeb/WOContext+SoObjects.h>
|
||||
|
|
|
@ -34,6 +34,7 @@
|
|||
#import <SOGo/SOGoUserManager.h>
|
||||
#import <SOGo/SOGoDateFormatter.h>
|
||||
#import <SOGo/SOGoUser.h>
|
||||
#import <SOGo/SOGoUserDefaults.h>
|
||||
|
||||
#import "SOGoAptMailReceipt.h"
|
||||
|
||||
|
|
|
@ -25,6 +25,7 @@
|
|||
#import <GDLContentStore/GCSFolder.h>
|
||||
#import <NGObjWeb/WOContext+SoObjects.h>
|
||||
#import <SoObjects/SOGo/SOGoUser.h>
|
||||
#import <SoObjects/SOGo/SOGoUserSettings.h>
|
||||
|
||||
#import "SOGoWebAppointmentFolder.h"
|
||||
|
||||
|
|
|
@ -32,12 +32,14 @@
|
|||
#import <SOGo/NSObject+DAV.h>
|
||||
#import <SOGo/NSString+DAV.h>
|
||||
|
||||
#import "SOGoContactFolders.h"
|
||||
|
||||
#import "SOGoUserFolder+Contacts.h"
|
||||
|
||||
@interface SOGoUserFolder (private)
|
||||
|
||||
- (SOGoAppointmentFolders *) privateContacts: (NSString *) key
|
||||
inContext: (WOContext *) localContext;
|
||||
- (SOGoContactFolders *) privateContacts: (NSString *) key
|
||||
inContext: (WOContext *) localContext;
|
||||
|
||||
@end
|
||||
|
||||
|
@ -47,7 +49,7 @@
|
|||
- (NSArray *) davAddressbookHomeSet
|
||||
{
|
||||
NSArray *tag;
|
||||
SOGoAppointmentFolders *parent;
|
||||
SOGoContactFolders *parent;
|
||||
|
||||
parent = [self privateContacts: @"Contacts" inContext: context];
|
||||
tag = [NSArray arrayWithObjects: @"href", @"DAV:", @"D",
|
||||
|
|
|
@ -19,6 +19,7 @@
|
|||
02111-1307, USA.
|
||||
*/
|
||||
|
||||
#import <Foundation/NSData.h>
|
||||
#import <Foundation/NSDictionary.h>
|
||||
#import <Foundation/NSEnumerator.h>
|
||||
#import <Foundation/NSURL.h>
|
||||
|
|
|
@ -20,6 +20,8 @@
|
|||
* Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
#import <Foundation/NSDictionary.h>
|
||||
|
||||
#import <NGObjWeb/WOContext+SoObjects.h>
|
||||
#import <NGExtensions/NSString+misc.h>
|
||||
|
||||
|
@ -89,7 +91,8 @@
|
|||
NSString *rc;
|
||||
|
||||
if (htmlComposition)
|
||||
rc = [[[sourceMail mailHeaders] objectForKey: @"from"] stringByEscapingHTMLString];
|
||||
rc = [[[sourceMail mailHeaders] objectForKey: @"from"]
|
||||
stringByEscapingHTMLString];
|
||||
else
|
||||
rc = [[sourceMail mailHeaders] objectForKey: @"from"];
|
||||
|
||||
|
|
|
@ -30,6 +30,7 @@
|
|||
|
||||
#import <NGObjWeb/WOContext.h>
|
||||
#import <NGObjWeb/WOContext+SoObjects.h>
|
||||
#import <NGObjWeb/WORequest.h>
|
||||
#import <NGObjWeb/WOResponse.h>
|
||||
#import <NGObjWeb/NSException+HTTP.h>
|
||||
#import <NGExtensions/NGHashMap.h>
|
||||
|
|
|
@ -429,6 +429,8 @@ static NSDictionary *methodRequirements = nil;
|
|||
*flag, *mailbox;
|
||||
SOGoDomainDefaults *dd;
|
||||
|
||||
sieveAction = nil;
|
||||
|
||||
method = [action objectForKey: @"method"];
|
||||
if (method)
|
||||
{
|
||||
|
@ -484,10 +486,7 @@ static NSDictionary *methodRequirements = nil;
|
|||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
scriptError = @"Action missing 'method' parameter";
|
||||
sieveAction = nil;
|
||||
}
|
||||
scriptError = @"Action missing 'method' parameter";
|
||||
|
||||
return sieveAction;
|
||||
}
|
||||
|
|
|
@ -46,7 +46,7 @@
|
|||
andParameters: (NSDictionary *) parameters;
|
||||
|
||||
+ (SOGoCASSession *) CASSessionWithTicket: (NSString *) newTicket;
|
||||
+ (SOGoCASSession *) CASSessionWithIdentifier: (NSString *) identifier;
|
||||
+ (SOGoCASSession *) CASSessionWithIdentifier: (NSString *) newIdentifier;
|
||||
|
||||
- (NSString *) identifier;
|
||||
|
||||
|
|
|
@ -83,14 +83,14 @@
|
|||
return newSession;
|
||||
}
|
||||
|
||||
+ (SOGoCASSession *) CASSessionWithIdentifier: (NSString *) identifier
|
||||
+ (SOGoCASSession *) CASSessionWithIdentifier: (NSString *) newIdentifier
|
||||
{
|
||||
SOGoCASSession *session;
|
||||
SOGoCache *cache;
|
||||
NSString *casTicket;
|
||||
|
||||
cache = [SOGoCache sharedCache];
|
||||
casTicket = [cache CASTicketFromIdentifier: identifier];
|
||||
casTicket = [cache CASTicketFromIdentifier: newIdentifier];
|
||||
session = [self CASSessionWithTicket: casTicket];
|
||||
|
||||
return session;
|
||||
|
|
|
@ -27,8 +27,9 @@
|
|||
#import <NGObjWeb/WORequest.h>
|
||||
#import <NGObjWeb/WOSession.h>
|
||||
|
||||
#import <SOGoUser.h>
|
||||
#import <SOGoUserDefaults.h>
|
||||
#import "SOGoDomainDefaults.h"
|
||||
#import "SOGoUser.h"
|
||||
#import "SOGoUserDefaults.h"
|
||||
|
||||
#import "WOContext+SOGo.h"
|
||||
|
||||
|
|
|
@ -41,6 +41,7 @@
|
|||
#import <SOGo/SOGoUser.h>
|
||||
#import <SOGo/SOGoUserDefaults.h>
|
||||
#import <SOGo/SOGoUserManager.h>
|
||||
#import <SOGo/SOGoUserSettings.h>
|
||||
#import <SOGo/NSArray+Utilities.h>
|
||||
#import <SOGo/NSDictionary+Utilities.h>
|
||||
#import <SOGo/NSString+Utilities.h>
|
||||
|
|
|
@ -22,6 +22,7 @@
|
|||
|
||||
#import <Foundation/NSCalendarDate.h>
|
||||
#import <Foundation/NSEnumerator.h>
|
||||
#import <Foundation/NSValue.h>
|
||||
|
||||
#import <NGObjWeb/NSException+HTTP.h>
|
||||
#import <NGObjWeb/WOContext+SoObjects.h>
|
||||
|
@ -39,15 +40,16 @@
|
|||
|
||||
#import <NGImap4/NGImap4EnvelopeAddress.h>
|
||||
|
||||
#import <SoObjects/Appointments/iCalEvent+SOGo.h>
|
||||
#import <SoObjects/Appointments/iCalPerson+SOGo.h>
|
||||
#import <SoObjects/Appointments/SOGoAppointmentObject.h>
|
||||
#import <SoObjects/Appointments/SOGoAppointmentFolder.h>
|
||||
#import <SoObjects/Mailer/SOGoMailObject.h>
|
||||
#import <SoObjects/SOGo/SOGoParentFolder.h>
|
||||
#import <SoObjects/SOGo/SOGoUser.h>
|
||||
#import <SoObjects/SOGo/iCalEntityObject+Utilities.h>
|
||||
#import <SoObjects/Mailer/SOGoMailBodyPart.h>
|
||||
#import <Appointments/iCalEvent+SOGo.h>
|
||||
#import <Appointments/iCalPerson+SOGo.h>
|
||||
#import <Appointments/SOGoAppointmentObject.h>
|
||||
#import <Appointments/SOGoAppointmentFolder.h>
|
||||
#import <Appointments/SOGoAppointmentFolders.h>
|
||||
#import <Mailer/SOGoMailObject.h>
|
||||
#import <SOGo/SOGoParentFolder.h>
|
||||
#import <SOGo/SOGoUser.h>
|
||||
#import <SOGo/iCalEntityObject+Utilities.h>
|
||||
#import <Mailer/SOGoMailBodyPart.h>
|
||||
|
||||
#import "UIxMailPartICalActions.h"
|
||||
|
||||
|
|
|
@ -25,6 +25,8 @@
|
|||
Show plain/calendar mail parts.
|
||||
*/
|
||||
|
||||
#import <Foundation/NSValue.h>
|
||||
|
||||
#import <NGObjWeb/WOResponse.h>
|
||||
|
||||
#import <NGExtensions/NSCalendarDate+misc.h>
|
||||
|
@ -39,6 +41,7 @@
|
|||
|
||||
#import <SOGo/SOGoDateFormatter.h>
|
||||
#import <SOGo/SOGoUser.h>
|
||||
#import <SOGo/SOGoUserFolder.h>
|
||||
#import <SOGo/SOGoUserDefaults.h>
|
||||
#import <SOGo/iCalEntityObject+Utilities.h>
|
||||
#import <Appointments/iCalEntityObject+SOGo.h>
|
||||
|
|
|
@ -25,6 +25,7 @@
|
|||
#import <Foundation/NSKeyValueCoding.h>
|
||||
#import <Foundation/NSString.h>
|
||||
|
||||
#import <NGHttp/NGHttpRequest.h>
|
||||
#import <NGObjWeb/NSException+HTTP.h>
|
||||
#import <NGObjWeb/SoSubContext.h>
|
||||
#define COMPILING_NGOBJWEB 1 /* we want httpRequest for parsing multi-part
|
||||
|
@ -41,6 +42,7 @@
|
|||
#import <NGMime/NGMimeBodyPart.h>
|
||||
#import <NGMime/NGMimeHeaderFields.h>
|
||||
#import <NGMime/NGMimeMultipartBody.h>
|
||||
#import <NGMime/NGMimeType.h>
|
||||
|
||||
#import <SoObjects/Mailer/SOGoDraftObject.h>
|
||||
#import <SoObjects/Mailer/SOGoMailFolder.h>
|
||||
|
|
|
@ -39,6 +39,7 @@
|
|||
#import <SOGo/NSObject+Utilities.h>
|
||||
#import <SOGo/SOGoUser.h>
|
||||
#import <SOGo/SOGoUserDefaults.h>
|
||||
#import <SOGo/SOGoUserSettings.h>
|
||||
|
||||
#import <UI/Common/WODirectAction+SOGo.h>
|
||||
|
||||
|
|
|
@ -45,9 +45,11 @@
|
|||
#import <SOGo/NSArray+Utilities.h>
|
||||
#import <SOGo/NSString+Utilities.h>
|
||||
#import <SOGo/NSDictionary+Utilities.h>
|
||||
#import <SOGo/SOGoDomainDefaults.h>
|
||||
#import <SOGo/SOGoUser.h>
|
||||
#import <SOGo/SOGoUserDefaults.h>
|
||||
#import <SOGo/SOGoUserFolder.h>
|
||||
#import <SOGo/SOGoUserSettings.h>
|
||||
#import <SOGoUI/UIxComponent.h>
|
||||
|
||||
#import "UIxMailMainFrame.h"
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
* Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
#import <Foundation/NSDictionary.h>
|
||||
#import <Foundation/NSURL.h>
|
||||
|
||||
#import <NGObjWeb/WOResponse.h>
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
* Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
#import <Foundation/NSDictionary.h>
|
||||
#import <Foundation/NSURL.h>
|
||||
|
||||
#import <NGObjWeb/WOResponse.h>
|
||||
|
|
|
@ -28,8 +28,9 @@
|
|||
|
||||
#import <NGExtensions/NSCalendarDate+misc.h>
|
||||
|
||||
#import <SoObjects/SOGo/SOGoUser.h>
|
||||
#import <SoObjects/SOGo/SOGoDateFormatter.h>
|
||||
#import <SOGo/SOGoUser.h>
|
||||
#import <SOGo/SOGoUserDefaults.h>
|
||||
#import <SOGo/SOGoDateFormatter.h>
|
||||
|
||||
#import "UIxCalMulticolumnDayView.h"
|
||||
|
||||
|
|
Loading…
Reference in New Issue