public function serialize(ResourceUserEvaluation $resourceUserEvaluation)
    {
        $serialized = [
            'id' => $resourceUserEvaluation->getId(),
            'date' => $resourceUserEvaluation->getDate() ? $resourceUserEvaluation->getDate()->format('Y-m-d H:i') : null,
            'status' => $resourceUserEvaluation->getStatus(),
            'duration' => $resourceUserEvaluation->getDuration(),
            'score' => $resourceUserEvaluation->getScore(),
            'scoreMin' => $resourceUserEvaluation->getScoreMin(),
            'scoreMax' => $resourceUserEvaluation->getScoreMax(),
            'customScore' => $resourceUserEvaluation->getCustomScore(),
            'progression' => $resourceUserEvaluation->getProgression(),
            'resourceNode' => $this->resourceNodeSerializer->serialize($resourceUserEvaluation->getResourceNode()),
            'user' => $this->userSerializer->serialize($resourceUserEvaluation->getUser()),
            'userName' => $resourceUserEvaluation->getUserName(),
            'nbAttempts' => $resourceUserEvaluation->getNbAttempts(),
            'nbOpenings' => $resourceUserEvaluation->getNbOpenings(),
        ];

        return $serialized;
    }