/**
  * @param string $ticketNumber
  *
  * @return Ticket
  */
 public function findByTicketNumber($ticketNumber)
 {
     /** @var Ticket */
     if (!($ticket = $this->service->findByTicketNumber($ticketNumber))) {
         throw new NotFoundHttpException();
     }
     return $ticket;
 }
 /**
  * @param string $ticketNumber
  *
  * @return Resource
  */
 public function findByTicketNumber($ticketNumber)
 {
     return new Resource($this->service->findByTicketNumber($ticketNumber), $this->serializer);
 }