1: <?php
2: /**
3: * The Horde_Kolab_Session_Factory_Imap class allows to dependency inject the
4: * IMAP client.
5: *
6: * PHP version 5
7: *
8: * @category Kolab
9: * @package Kolab_Session
10: * @author Gunnar Wrobel <wrobel@pardus.de>
11: * @license http://www.horde.org/licenses/lgpl21 LGPL 2.1
12: * @link http://pear.horde.org/index.php?package=Kolab_Session
13: */
14:
15: /**
16: * The Horde_Kolab_Session_Factory_Imap class allows to dependency inject the
17: * IMAP client.
18: *
19: * @todo Rename from Horde_Kolab_Session_Base ->
20: * Horde_Kolab_Session_Ldap at some point.
21: *
22: * Copyright 2011-2012 Horde LLC (http://www.horde.org/)
23: *
24: * See the enclosed file COPYING for license information (LGPL). If you
25: * did not receive this file, see http://www.horde.org/licenses/lgpl21.
26: *
27: * @category Kolab
28: * @package Kolab_Session
29: * @author Gunnar Wrobel <wrobel@pardus.de>
30: * @license http://www.horde.org/licenses/lgpl21 LGPL 2.1
31: * @link http://pear.horde.org/index.php?package=Kolab_Session
32: */
33: class Horde_Kolab_Session_Factory_Imap
34: {
35: /**
36: * Create the IMAP client.
37: *
38: * @param array $params The connection parameters for the IMAP client.
39: *
40: * @return Horde_Imap_Client_Base The IMAP client.
41: */
42: public function create($params)
43: {
44: return Horde_Imap_Client::factory('Socket', $params);
45: }
46: }
47: