function getGroups($type) { if (isset($this->groups[$type])) { return $this->groups[$type]; } return array(); }