00001 <?php 00002 /*************************************************************************** 00003 * Copyright (C) 2007 by Dmitry A. Lomash, Dmitry E. Demidov * 00004 * * 00005 * This program is free software; you can redistribute it and/or modify * 00006 * it under the terms of the GNU Lesser General Public License as * 00007 * published by the Free Software Foundation; either version 3 of the * 00008 * License, or (at your option) any later version. * 00009 * * 00010 ***************************************************************************/ 00011 /* $Id: FeedChannel.class.php 4687 2007-12-09 18:57:18Z voxus $ */ 00012 00016 final class FeedChannel 00017 { 00018 private $title = null; 00019 private $link = null; 00020 private $description = null; 00021 private $feedItems = array(); 00022 00026 public static function create($title) 00027 { 00028 return new self($title); 00029 } 00030 00031 public function __construct($title) 00032 { 00033 $this->title = $title; 00034 } 00035 00036 public function getTitle() 00037 { 00038 return $this->title; 00039 } 00040 00044 public function setTitle($title) 00045 { 00046 $this->title = $title; 00047 00048 return $this; 00049 } 00050 00051 public function getDescription() 00052 { 00053 return $this->description; 00054 } 00055 00059 public function setDescription($description) 00060 { 00061 $this->description = $description; 00062 00063 return $this; 00064 } 00065 00066 public function getLink() 00067 { 00068 return $this->link; 00069 } 00070 00074 public function setLink($link) 00075 { 00076 $this->link = $link; 00077 00078 return $this; 00079 } 00080 00081 public function getFeedItems() 00082 { 00083 return $this->feedItems; 00084 } 00085 00089 public function setFeedItems($feedItems) 00090 { 00091 $this->feedItems = $feedItems; 00092 00093 return $this; 00094 } 00095 00099 public function addFeedItem(FeedItem $feedItem) 00100 { 00101 $this->feedItems[] = $feedItem; 00102 00103 return $this; 00104 } 00105 } 00106 ?>