PHP Class Owl\Services\CommentService

Inheritance: extends Service
Afficher le fichier Open project: owl/owl

Protected Properties

Свойство Type Description
$commentRepo

Méthodes publiques

Méthode Description
__construct ( Owl\Repositories\CommentRepositoryInterface $commentRepo )
createComment ( $cmt ) : Illuminate\Database\Eloquent\Model Create a new comment.
deleteComment ( $id ) : boolean Delete a comment.
getCommentById ( $id ) : Illuminate\Database\Eloquent\Model Get a comment by comment id.
updateComment ( $id, $body ) : Illuminate\Database\Eloquent\Model Update a comment's body.

Method Details

__construct() public méthode

public __construct ( Owl\Repositories\CommentRepositoryInterface $commentRepo )
$commentRepo Owl\Repositories\CommentRepositoryInterface

createComment() public méthode

Create a new comment.
public createComment ( $cmt ) : Illuminate\Database\Eloquent\Model
Résultat Illuminate\Database\Eloquent\Model

deleteComment() public méthode

Delete a comment.
public deleteComment ( $id ) : boolean
$id int
Résultat boolean

getCommentById() public méthode

Get a comment by comment id.
public getCommentById ( $id ) : Illuminate\Database\Eloquent\Model
$id int
Résultat Illuminate\Database\Eloquent\Model

updateComment() public méthode

Update a comment's body.
public updateComment ( $id, $body ) : Illuminate\Database\Eloquent\Model
$id int
$body string
Résultat Illuminate\Database\Eloquent\Model

Property Details

$commentRepo protected_oe property

protected $commentRepo