phpDocumentor

ReviewReadService
in package
implements ReviewReadServiceInterface

Class ReviewReadService

Tags
category

System

subpackage

Services

Interfaces, Classes and Traits

ReviewReadServiceInterface
Interface ReviewReadServiceInterface

Table of Contents

$repository  : ReviewAccessRepositoryInterface
__construct()  : mixed
ReviewReadService constructor.
getAll()  : ReviewCollection
Returns all review entities as array.
getAverageRatingByProductId()  : float
Returns the average rating by given product id.
getById()  : Review
Returns review entity data by the given id.
getReviewsByCustomerId()  : ReviewCollection
Returns the reviews by given customer ID.
getReviewsByProductId()  : ReviewCollection
Returns the reviews by given product id.

Properties

Methods

getAverageRatingByProductId()

Returns the average rating by given product id.

public getAverageRatingByProductId(IdType $productId) : float
Parameters
$productId : IdType
Return values
float

Search results