Monotone-Parent: da9c14ddfb4c9a9c929c7b84543af4ce664cfc10

Monotone-Revision: 829ccf73000a2d91a5daf67741479e395011b6a8

Monotone-Author: wsourdeau@inverse.ca
Monotone-Date: 2011-07-26T20:13:10
Monotone-Branch: ca.inverse.sogo
This commit is contained in:
Wolfgang Sourdeau
2011-07-26 20:13:10 +00:00
parent b95cd69e4b
commit aad817d5ca
19 changed files with 307 additions and 150 deletions
+39
View File
@@ -20,12 +20,51 @@
* Boston, MA 02111-1307, USA.
*/
#import <Foundation/NSArray.h>
#import "MAPIStoreMessage.h"
#import "MAPIStoreAttachmentTable.h"
@implementation MAPIStoreAttachmentTable
- (NSArray *) childKeys
{
if (!childKeys)
{
childKeys = [(MAPIStoreMessage *)
container attachmentKeysMatchingQualifier: nil
andSortOrderings: sortOrderings];
[childKeys retain];
}
return childKeys;
}
- (NSArray *) restrictedChildKeys
{
NSArray *keys;
if (!restrictedChildKeys)
{
if (restrictionState != MAPIRestrictionStateAlwaysTrue)
{
if (restrictionState == MAPIRestrictionStateNeedsEval)
keys = [(MAPIStoreMessage *)
container attachmentKeysMatchingQualifier: restriction
andSortOrderings: sortOrderings];
else
keys = [NSArray array];
}
else
keys = [self childKeys];
ASSIGN (restrictedChildKeys, keys);
}
return restrictedChildKeys;
}
- (id) lookupChild: (NSString *) childKey
{
return [(MAPIStoreMessage *) container lookupAttachment: childKey];