socialPostRepository = $socialPostRepository; } /** * @param int $postId [description] * * @return array|null [description] */ public function read(SocialPost $post) { $result = new PostView( $post->getId(), $post->getSocialNetwork(), $post->getTitle(), !empty($post->getDateBeginPost()) ? $post->getDateBeginPost()->format("y/m/d") : null, !empty($post->getDateEndPost()) ? $post->getDateEndPost()->format("y/m/d") : null, $post->getMessage(), $post->getHashtag(), $post->getMediasId(), $post->getCanLike(), $post->getCanComment(), $post->getCanShare(), $post->getPostDiffusion(), $post->getPostResponse() ); return $result; } }