3 final class PhabricatorPackagesPublisherListView
4 extends PhabricatorPackagesView
{
8 public function setPublishers(array $publishers) {
9 assert_instances_of($publishers, 'PhabricatorPackagesPublisher');
10 $this->publishers
= $publishers;
14 public function getPublishers() {
15 return $this->publishers
;
18 public function render() {
19 return $this->newListView();
22 public function newListView() {
23 $viewer = $this->getViewer();
24 $publishers = $this->getPublishers();
26 $list = id(new PHUIObjectItemListView())
29 foreach ($publishers as $publisher) {
30 $item = id(new PHUIObjectItemView())
31 ->setObjectName($publisher->getPublisherKey())
32 ->setHeader($publisher->getName())
33 ->setHref($publisher->getURI());
35 $list->addItem($item);