Pop\Feed\Reader::isRss PHP Method

isRss() public method

Method to determine if the feed type is RSS
public isRss ( ) : boolean
return boolean
    public function isRss()
    {
        return strpos(get_class($this->adapter), 'Rss') !== false;
    }

Usage Example

Exemplo n.º 1
0
 public function testBooleanMethods()
 {
     $feed = new Feed\Reader(new Feed\Format\Atom('http://gdata.youtube.com/feeds/base/standardfeeds/most_viewed', 4));
     $this->assertTrue($feed->isAtom());
     $this->assertFalse($feed->isRss());
     $this->assertFalse($feed->isJson());
     $this->assertFalse($feed->isPhp());
     $this->assertTrue($feed->isYoutube());
     $this->assertFalse($feed->isFacebook());
     $this->assertFalse($feed->isTwitter());
     $this->assertFalse($feed->isVimeo());
     $this->assertFalse($feed->isPlaylist());
 }