style(addressbook(obj-c)): add comments

pull/301/head
Francis Lachapelle 2021-08-18 13:32:33 -04:00
parent fef5003d92
commit 00846c463c
3 changed files with 13 additions and 2 deletions

View File

@ -480,6 +480,7 @@ convention:
max = [elements count];
if (max > 0)
{
// We convert two email addresses at most
workMail = [self _simpleValueForType: @"work"
inArray: elements excluding: nil];
homeMail = [self _simpleValueForType: @"home"
@ -539,6 +540,11 @@ convention:
}
}
/**
* Convert vCard to LDIF using the Mozilla LDAP Address Book Schema
*
* https://wiki.mozilla.org/MailNews:Mozilla_LDAP_Address_Book_Schema
*/
- (NSMutableDictionary *) asLDIFRecord
{
NSArray *elements, *categories;

View File

@ -1,6 +1,5 @@
/*
Copyright (C) 2006-2011 Inverse inc.
Copyright (C) 2004-2005 SKYRIX Software AG
Copyright (C) 2006-2017 Inverse inc.
This file is part of SOGo.

View File

@ -136,8 +136,14 @@
NSArray *type;
resourceType = [NSMutableArray arrayWithArray: [super davResourceType]];
// CARDDAV:addressbook
// https://datatracker.ietf.org/doc/html/rfc6352#section-5.2
type = [NSArray arrayWithObjects: @"addressbook", XMLNS_CARDDAV, nil];
[resourceType addObject: type];
// CARDDAV:directory
// https://datatracker.ietf.org/doc/html/draft-daboo-carddav-directory-gateway-02#section-4.1
type = [NSArray arrayWithObjects: @"directory", XMLNS_CARDDAV, nil];
[resourceType addObject: type];