1: <?php
2: /**
3: * Implement the Horde_Data:: API for vCard data.
4: *
5: * Copyright 1999-2012 Horde LLC (http://www.horde.org/)
6: *
7: * See the enclosed file COPYING for license information (LGPL). If you
8: * did not receive this file, see http://www.horde.org/licenses/lgpl21.
9: *
10: * @author Jan Schneider <jan@horde.org>
11: * @category Horde
12: * @package Data
13: */
14: class Horde_Data_Vcard extends Horde_Data_Imc {
15:
16: /**
17: * Exports vcalendar data as a string. Unlike vEvent, vCard data
18: * is not enclosed in BEGIN|END:vCalendar.
19: *
20: * @param array $data An array containing Horde_Icalendar_Vcard
21: * objects.
22: * @param string $method The iTip method to use.
23: *
24: * @return string The iCalendar data.
25: */
26: public function exportData($data, $method = 'REQUEST')
27: {
28: $s = '';
29:
30: foreach ($data as $vcard) {
31: $s.= $vcard->exportvCalendar();
32: }
33:
34: return $s;
35: }
36:
37: }
38: