public static function setUpBeforeClass() { self::$linkCollection = LinkCollection::factory(array(array('id' => 1, 'type' => 'category', 'value' => 'category a'), array('id' => 2, 'type' => 'mechanic', 'value' => 'mechanic a'), array('id' => 3, 'type' => 'designer', 'value' => 'designer a'), array('id' => 4, 'type' => 'artist', 'value' => 'artist a'), array('id' => 5, 'type' => 'publisher', 'value' => 'publisher a'), array('id' => 6, 'type' => 'family', 'value' => 'family a'), array('id' => 7, 'type' => 'expansion', 'value' => 'expansion a'), array('id' => 17, 'type' => 'compilation', 'value' => 'compilation a'), array('id' => 8, 'type' => 'implementation', 'value' => 'implementation a'), array('id' => 9, 'type' => 'category', 'value' => 'category b'), array('id' => 10, 'type' => 'mechanic', 'value' => 'mechanic b'), array('id' => 11, 'type' => 'designer', 'value' => 'designer b'), array('id' => 12, 'type' => 'artist', 'value' => 'artist b'), array('id' => 13, 'type' => 'publisher', 'value' => 'publisher b'), array('id' => 14, 'type' => 'family', 'value' => 'family b'), array('id' => 15, 'type' => 'expansion', 'value' => 'expansion b'), array('id' => 18, 'type' => 'compilation', 'value' => 'compilation b'), array('id' => 16, 'type' => 'implementation', 'value' => 'implementation b'))); }
/** * Returns the links associated with a boardgame * * @return LinkCollection */ public function getLinks() { if ($this->linkCollection === null) { $this->linkCollection = LinkCollection::factory(parent::getLinks()); } return $this->linkCollection; }