diff options
Diffstat (limited to 'vendor/simplepie/simplepie/library/SimplePie/Rating.php')
-rw-r--r-- | vendor/simplepie/simplepie/library/SimplePie/Rating.php | 89 |
1 files changed, 9 insertions, 80 deletions
diff --git a/vendor/simplepie/simplepie/library/SimplePie/Rating.php b/vendor/simplepie/simplepie/library/SimplePie/Rating.php index eae6718a7..69ca4eff1 100644 --- a/vendor/simplepie/simplepie/library/SimplePie/Rating.php +++ b/vendor/simplepie/simplepie/library/SimplePie/Rating.php @@ -5,7 +5,7 @@ * A PHP-Based RSS and Atom Feed Framework. * Takes the hard work out of managing a complete RSS/Atom solution. * - * Copyright (c) 2004-2016, Ryan Parman, Sam Sneddon, Ryan McCue, and contributors + * Copyright (c) 2004-2022, Ryan Parman, Sam Sneddon, Ryan McCue, and contributors * All rights reserved. * * Redistribution and use in source and binary forms, with or without modification, are @@ -41,86 +41,15 @@ * @license http://www.opensource.org/licenses/bsd-license.php BSD License */ -/** - * Handles `<media:rating>` or `<itunes:explicit>` tags as defined in Media RSS and iTunes RSS respectively - * - * Used by {@see SimplePie_Enclosure::get_rating()} and {@see SimplePie_Enclosure::get_ratings()} - * - * This class can be overloaded with {@see SimplePie::set_rating_class()} - * - * @package SimplePie - * @subpackage API - */ -class SimplePie_Rating -{ - /** - * Rating scheme - * - * @var string - * @see get_scheme() - */ - var $scheme; +use SimplePie\Rating; - /** - * Rating value - * - * @var string - * @see get_value() - */ - var $value; +class_exists('SimplePie\Rating'); - /** - * Constructor, used to input the data - * - * For documentation on all the parameters, see the corresponding - * properties and their accessors - */ - public function __construct($scheme = null, $value = null) - { - $this->scheme = $scheme; - $this->value = $value; - } +// @trigger_error(sprintf('Using the "SimplePie_Rating" class is deprecated since SimplePie 1.7, use "SimplePie\Rating" instead.'), \E_USER_DEPRECATED); - /** - * String-ified version - * - * @return string - */ - public function __toString() - { - // There is no $this->data here - return md5(serialize($this)); - } - - /** - * Get the organizational scheme for the rating - * - * @return string|null - */ - public function get_scheme() - { - if ($this->scheme !== null) - { - return $this->scheme; - } - - return null; - } - - /** - * Get the value of the rating - * - * @return string|null - */ - public function get_value() - { - if ($this->value !== null) - { - return $this->value; - } - - return null; - } +if (\false) { + /** @deprecated since SimplePie 1.7, use "SimplePie\Rating" instead */ + class SimplePie_Rating extends Rating + { + } } - -class_alias('SimplePie_Rating', 'SimplePie\Rating', false); |