annotate vendor/zendframework/zend-feed/src/Reader/ReaderImportInterface.php @ 19:fa3358dc1485 tip

Add ndrum files
author Chris Cannam
date Wed, 28 Aug 2019 13:14:47 +0100
parents 4c8ae668cc8c
children
rev   line source
Chris@0 1 <?php
Chris@0 2
Chris@0 3 /**
Chris@0 4 * Zend Framework (http://framework.zend.com/)
Chris@0 5 *
Chris@0 6 * @link http://github.com/zendframework/zf2 for the canonical source repository
Chris@0 7 * @copyright Copyright (c) 2005-2015 Zend Technologies USA Inc. (http://www.zend.com)
Chris@0 8 * @license http://framework.zend.com/license/new-bsd New BSD License
Chris@0 9 */
Chris@0 10
Chris@0 11 namespace Zend\Feed\Reader;
Chris@0 12
Chris@0 13 interface ReaderImportInterface
Chris@0 14 {
Chris@0 15 /**
Chris@0 16 * Import a feed by providing a URI
Chris@0 17 *
Chris@0 18 * @param string $uri The URI to the feed
Chris@0 19 * @param string $etag OPTIONAL Last received ETag for this resource
Chris@0 20 * @param string $lastModified OPTIONAL Last-Modified value for this resource
Chris@0 21 * @return Feed\FeedInterface
Chris@0 22 * @throws Exception\RuntimeException
Chris@0 23 */
Chris@0 24 public static function import($uri, $etag = null, $lastModified = null);
Chris@0 25
Chris@0 26 /**
Chris@0 27 * Import a feed from a remote URI
Chris@0 28 *
Chris@0 29 * Performs similarly to import(), except it uses the HTTP client passed to
Chris@0 30 * the method, and does not take into account cached data.
Chris@0 31 *
Chris@0 32 * Primary purpose is to make it possible to use the Reader with alternate
Chris@0 33 * HTTP client implementations.
Chris@0 34 *
Chris@0 35 * @param string $uri
Chris@0 36 * @param Http\ClientInterface $client
Chris@0 37 * @return self
Chris@0 38 * @throws Exception\RuntimeException if response is not an Http\ResponseInterface
Chris@0 39 */
Chris@0 40 public static function importRemoteFeed($uri, Http\ClientInterface $client);
Chris@0 41
Chris@0 42
Chris@0 43 /**
Chris@0 44 * Import a feed from a string
Chris@0 45 *
Chris@0 46 * @param string $string
Chris@0 47 * @return Feed\FeedInterface
Chris@0 48 * @throws Exception\InvalidArgumentException
Chris@0 49 * @throws Exception\RuntimeException
Chris@0 50 */
Chris@0 51 public static function importString($string);
Chris@0 52
Chris@0 53
Chris@0 54 /**
Chris@0 55 * Imports a feed from a file located at $filename.
Chris@0 56 *
Chris@0 57 * @param string $filename
Chris@0 58 * @throws Exception\RuntimeException
Chris@0 59 * @return Feed\FeedInterface
Chris@0 60 */
Chris@0 61 public static function importFile($filename);
Chris@0 62 }