composer package updates
[openemr.git] / vendor / zendframework / zend-feed / src / Reader / Extension / GooglePlayPodcast / Entry.php
blob0ce6cda7a8ba30aa9740fa8d11b62a89fa3649d5
1 <?php
2 /**
3 * @see https://github.com/zendframework/zend-feed for the canonical source repository
4 * @copyright Copyright (c) 2018 Zend Technologies USA Inc. (https://www.zend.com)
5 * @license https://github.com/zendframework/zend-feed/blob/master/LICENSE.md New BSD License
6 */
8 namespace Zend\Feed\Reader\Extension\GooglePlayPodcast;
10 use Zend\Feed\Reader\Extension;
12 class Entry extends Extension\AbstractEntry
14 /**
15 * Get the entry block
17 * @return string
19 public function getPlayPodcastBlock()
21 if (isset($this->data['block'])) {
22 return $this->data['block'];
25 $block = $this->xpath->evaluate('string(' . $this->getXpathPrefix() . '/googleplay:block)');
27 if (! $block) {
28 $block = null;
31 $this->data['block'] = $block;
33 return $this->data['block'];
36 /**
37 * Get the entry explicit
39 * @return string
41 public function getPlayPodcastExplicit()
43 if (isset($this->data['explicit'])) {
44 return $this->data['explicit'];
47 $explicit = $this->xpath->evaluate('string(' . $this->getXpathPrefix() . '/googleplay:explicit)');
49 if (! $explicit) {
50 $explicit = null;
53 $this->data['explicit'] = $explicit;
55 return $this->data['explicit'];
58 /**
59 * Get the episode summary/description
61 * Uses verbiage so it does not conflict with base entry.
63 * @return string
65 public function getPlayPodcastDescription()
67 if (isset($this->data['description'])) {
68 return $this->data['description'];
71 $description = $this->xpath->evaluate('string(' . $this->getXpathPrefix() . '/googleplay:description)');
73 if (! $description) {
74 $description = null;
77 $this->data['description'] = $description;
79 return $this->data['description'];
82 /**
83 * Register googleplay namespace
86 protected function registerNamespaces()
88 $this->xpath->registerNamespace('googleplay', 'http://www.google.com/schemas/play-podcasts/1.0');