1: <?php
2: /**
3: * This file contains the Horde_Service_UrlShortener class for shortening URLs.
4: *
5: * Copyright 2011-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 Michael J Rubinsky <mrubinsk@horde.org>
11: * @license http://www.horde.org/licenses/lgpl21 LGPL 2.1
12: * @category Horde
13: * @package Service_UrlShortener
14: */
15:
16: /**
17: * Horde_Service_UrlShortener Base class
18: *
19: * @author Michael J Rubinsky <mrubinsk@horde.org>
20: * @category Horde
21: * @package Service_UrlShortener
22: */
23: abstract class Horde_Service_UrlShortener_Base
24: {
25: /**
26: * @var array
27: */
28: protected $_params;
29:
30: /**
31: * @var Horde_Http_Client
32: */
33: protected $_http;
34:
35: /**
36: * Constructor
37: *
38: * @param Horde_Http_Client $http [description]
39: * @param array $params = array() [description]
40: *
41: * @return Horde_UrlShorten
42: */
43: public function __construct(Horde_Http_Client $http, $params = array())
44: {
45: $this->_http = $http;
46: $this->_params = $params;
47: }
48:
49: abstract public function shorten($url);
50: }