From 06f945f27840b53e57795dadbc38e76f7e11ab1c Mon Sep 17 00:00:00 2001 From: Horus3 Date: Mon, 24 Feb 2014 16:42:14 +0100 Subject: init --- zend/library/Zend/Gdata/Photos/PhotoQuery.php | 98 +++++++++++++++++++++++++++ 1 file changed, 98 insertions(+) create mode 100755 zend/library/Zend/Gdata/Photos/PhotoQuery.php (limited to 'zend/library/Zend/Gdata/Photos/PhotoQuery.php') diff --git a/zend/library/Zend/Gdata/Photos/PhotoQuery.php b/zend/library/Zend/Gdata/Photos/PhotoQuery.php new file mode 100755 index 0000000..881212d --- /dev/null +++ b/zend/library/Zend/Gdata/Photos/PhotoQuery.php @@ -0,0 +1,98 @@ +_photoId = $value; + } + + /** + * Get the photo ID which is to be returned. + * + * @see setPhoto + * @return string The ID of the photo to retrieve. + */ + public function getPhotoId() + { + return $this->_photoId; + } + + /** + * Returns the URL generated for this query, based on it's current + * parameters. + * + * @return string A URL generated based on the state of this query. + * @throws Zend_Gdata_App_InvalidArgumentException + */ + public function getQueryUrl($incomingUri = '') + { + $uri = ''; + if ($this->getPhotoId() !== null) { + $uri .= '/photoid/' . $this->getPhotoId(); + } else { + require_once 'Zend/Gdata/App/InvalidArgumentException.php'; + throw new Zend_Gdata_App_InvalidArgumentException( + 'PhotoId cannot be null'); + } + $uri .= $incomingUri; + return parent::getQueryUrl($uri); + } + +} -- cgit v1.2.3