示例#1
0
 /**
  * Retrieves a specific volume entry.
  *
  * @param string|null $volumeId The volumeId of interest.
  * @param \Zend\GData\Query|string|null $location (optional) The URL to
  *        query or a Zend_Gdata_Query object from which a URL can be
  *        determined.
  * @return \Zend\GData\Books\VolumeEntry The feed of volumes found at the
  *         specified URL.
  */
 public function getVolumeEntry($volumeId = null, $location = null)
 {
     if ($volumeId !== null) {
         $uri = self::VOLUME_FEED_URI . "/" . $volumeId;
     } elseif ($location instanceof Query) {
         $uri = $location->getQueryUrl();
     } else {
         $uri = $location;
     }
     return parent::getEntry($uri, 'Zend\\GData\\Books\\VolumeEntry');
 }
示例#2
0
 /**
  * Retreive entryobject
  *
  * @return \ZendGData\Calendar\ListEntry
  */
 public function getCalendarListEntry($location = null)
 {
     if ($location == null) {
         throw new App\InvalidArgumentException('Location must not be null');
     } elseif ($location instanceof Query) {
         $uri = $location->getQueryUrl();
     } else {
         $uri = $location;
     }
     return parent::getEntry($uri, 'ZendGData\\Calendar\\ListEntry');
 }
示例#3
0
文件: GApps.php 项目: rexmac/zf2
 /**
  * Retreive a single EmailListRecipientEntry object.
  *
  * @param mixed $location The location for the feed, as a URL or Query.
  * @return \Zend\GData\GApps\EmailListRecipientEntry
  * @throws \Zend\GData\App\Exception
  * @throws \Zend\GData\App\HttpException
  * @throws \Zend\GData\GApps\ServiceException
  */
 public function getEmailListRecipientEntry($location)
 {
     if ($location === null) {
         throw new App\InvalidArgumentException('Location must not be null');
     } else {
         if ($location instanceof Query) {
             $uri = $location->getQueryUrl();
         } else {
             $uri = $location;
         }
     }
     return parent::getEntry($uri, 'Zend\\GData\\GApps\\EmailListRecipientEntry');
 }
示例#4
0
 /**
  * Retreive a single CommentEntry object.
  *
  * @param mixed $location The location for the feed, as a URL or Query.
  * @return \ZendGData\Photos\CommentEntry
  * @throws \ZendGData\App\Exception
  * @throws \ZendGData\App\HttpException
  */
 public function getCommentEntry($location)
 {
     if ($location === null) {
         throw new App\InvalidArgumentException('Location must not be null');
     } elseif ($location instanceof Photos\UserQuery) {
         $location->setType('entry');
         $uri = $location->getQueryUrl();
     } elseif ($location instanceof Query) {
         $uri = $location->getQueryUrl();
     } else {
         $uri = $location;
     }
     return parent::getEntry($uri, 'ZendGData\\Photos\\CommentEntry');
 }
示例#5
0
 /**
  * Gets a list entry.
  *
  * @param string $location A ListQuery or a URI specifying the entry location.
  * @return ListEntry
  */
 public function getListEntry($location)
 {
     if ($location instanceof Spreadsheets\ListQuery) {
         $uri = $location->getQueryUrl();
     } else {
         $uri = $location;
     }
     return parent::getEntry($uri, 'Zend\\GData\\Spreadsheets\\ListEntry');
 }
示例#6
0
 /**
  * Retrieve a profile entry object
  *
  * @param mixed $query The query for the feed, as a URL or Query
  * @return \Zend\GData\Health\ProfileEntry
  */
 public function getHealthProfileEntry($query = null)
 {
     if ($query === null) {
         throw new App\InvalidArgumentException('Query must not be null');
     } else {
         if ($query instanceof Query) {
             $uri = $query->getQueryUrl();
         } else {
             $uri = $query;
         }
     }
     return parent::getEntry($uri, 'Zend\\GData\\Health\\ProfileEntry');
 }