[ Index ]

PHP Cross Reference of moodle-2.8

title

Body

[close]

/lib/zend/Zend/Service/Flickr/ -> Result.php (source)

   1  <?php
   2  
   3  /**
   4   * Zend Framework
   5   *
   6   * LICENSE
   7   *
   8   * This source file is subject to the new BSD license that is bundled
   9   * with this package in the file LICENSE.txt.
  10   * It is also available through the world-wide-web at this URL:
  11   * http://framework.zend.com/license/new-bsd
  12   * If you did not receive a copy of the license and are unable to
  13   * obtain it through the world-wide-web, please send an email
  14   * to [email protected] so we can send you a copy immediately.
  15   *
  16   * @category   Zend
  17   * @package    Zend_Service
  18   * @subpackage Flickr
  19   * @copyright  Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
  20   * @license    http://framework.zend.com/license/new-bsd     New BSD License
  21   * @version    $Id$
  22   */
  23  
  24  
  25  /**
  26   * @category   Zend
  27   * @package    Zend_Service
  28   * @subpackage Flickr
  29   * @copyright  Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
  30   * @license    http://framework.zend.com/license/new-bsd     New BSD License
  31   */
  32  class Zend_Service_Flickr_Result
  33  {
  34      /**
  35       * The photo's Flickr ID.
  36       *
  37       * @var string
  38       */
  39      public $id;
  40  
  41      /**
  42       * The photo owner's NSID.
  43       *
  44       * @var string
  45       */
  46      public $owner;
  47  
  48      /**
  49       * A key used in URI construction.
  50       *
  51       * @var string
  52       */
  53      public $secret;
  54  
  55      /**
  56       * The servername to use for URI construction.
  57       *
  58       * @var string
  59       */
  60      public $server;
  61  
  62      /**
  63       * The photo's title.
  64       *
  65       * @var string
  66       */
  67      public $title;
  68  
  69      /**
  70       * Whether the photo is public.
  71       *
  72       * @var string
  73       */
  74      public $ispublic;
  75  
  76      /**
  77       * Whether the photo is visible to you because you are a friend of the owner.
  78       *
  79       * @var string
  80       */
  81      public $isfriend;
  82  
  83      /**
  84       * Whether the photo is visible to you because you are family of the owner.
  85       *
  86       * @var string
  87       */
  88      public $isfamily;
  89  
  90      /**
  91       * The license the photo is available under.
  92       *
  93       * @var string
  94       */
  95      public $license;
  96  
  97      /**
  98       * The date the photo was uploaded.
  99       *
 100       * @var string
 101       */
 102      public $dateupload;
 103  
 104      /**
 105       * The date the photo was taken.
 106       *
 107       * @var string
 108       */
 109      public $datetaken;
 110  
 111      /**
 112       * The screenname of the owner.
 113       *
 114       * @var string
 115       */
 116      public $ownername;
 117  
 118      /**
 119       * The server used in assembling icon URLs.
 120       *
 121       * @var string
 122       */
 123      public $iconserver;
 124  
 125      /**
 126       * A 75x75 pixel square thumbnail of the image.
 127       *
 128       * @var Zend_Service_Flickr_Image
 129       */
 130      public $Square;
 131  
 132      /**
 133       * A 100 pixel thumbnail of the image.
 134       *
 135       * @var Zend_Service_Flickr_Image
 136       */
 137      public $Thumbnail;
 138  
 139      /**
 140       * A 240 pixel version of the image.
 141       *
 142       * @var Zend_Service_Flickr_Image
 143       */
 144      public $Small;
 145  
 146      /**
 147       * A 500 pixel version of the image.
 148       *
 149       * @var Zend_Service_Flickr_Image
 150       */
 151      public $Medium;
 152  
 153      /**
 154       * A 640 pixel version of the image.
 155       *
 156       * @var Zend_Service_Flickr_Image
 157       */
 158      public $Large;
 159  
 160      /**
 161       * The original image.
 162       *
 163       * @var Zend_Service_Flickr_Image
 164       */
 165      public $Original;
 166  
 167      /**
 168       * Original Zend_Service_Flickr object.
 169       *
 170       * @var Zend_Service_Flickr
 171       */
 172      protected $_flickr;
 173  
 174      /**
 175       * Parse the Flickr Result
 176       *
 177       * @param  DOMElement          $image
 178       * @param  Zend_Service_Flickr $flickr Original Zend_Service_Flickr object with which the request was made
 179       * @return void
 180       */
 181      public function __construct(DOMElement $image, Zend_Service_Flickr $flickr)
 182      {
 183          $xpath = new DOMXPath($image->ownerDocument);
 184  
 185          foreach ($xpath->query('./@*', $image) as $property) {
 186              $this->{$property->name} = (string) $property->value;
 187          }
 188  
 189          $this->_flickr = $flickr;
 190  
 191          foreach ($this->_flickr->getImageDetails($this->id) as $k => $v) {
 192              $this->$k = $v;
 193          }
 194      }
 195  }


Generated: Fri Nov 28 20:29:05 2014 Cross-referenced by PHPXref 0.7.1