user; } /** * @param User $user * @return TimesheetQuery */ public function setUser(User $user = null) { $this->user = $user; return $this; } /** * Activity overwrites: setProject() and setCustomer() * * @return Activity */ public function getActivity() { return $this->activity; } /** * @param Activity $activity * @return TimesheetQuery */ public function setActivity(Activity $activity = null) { $this->activity = $activity; return $this; } /** * @return int */ public function getState() { return $this->state; } /** * @param int $state * @return TimesheetQuery */ public function setState($state) { if (!is_int($state) && $state != (int) $state) { return $this; } $state = (int) $state; if (in_array($state, [self::STATE_ALL, self::STATE_RUNNING, self::STATE_STOPPED], true)) { $this->state = $state; } return $this; } /** * @return \DateTime */ public function getBegin() { return $this->begin; } /** * @param \DateTime $begin * @return TimesheetQuery */ public function setBegin($begin) { $this->begin = $begin; return $this; } /** * @return \DateTime */ public function getEnd() { return $this->end; } /** * @param \DateTime $end * @return TimesheetQuery */ public function setEnd($end) { $this->end = $end; return $this; } }