visibility; } /** * @param int $visibility * @return $this */ public function setVisibility($visibility) { if (!is_int($visibility) && $visibility != (int) $visibility) { return $this; } $visibility = (int) $visibility; if (in_array($visibility, [self::SHOW_BOTH, self::SHOW_VISIBLE, self::SHOW_HIDDEN], true)) { $this->visibility = $visibility; } return $this; } /** * @return bool */ public function isExclusiveVisibility() { return $this->exclusiveVisibility; } /** * If set to true, this will ONLY filter the visibility on the main queried object. * * @param bool $exclusiveVisibility * @return $this */ public function setExclusiveVisibility($exclusiveVisibility) { $this->exclusiveVisibility = (bool) $exclusiveVisibility; return $this; } }