Package com.dzidzi.api
Interface CustomerReviewApi
public interface CustomerReviewApi
CustomerReviewApi contains all the api operations for handling
CustomerReview of
DzidziApp-
Method Summary
Modifier and TypeMethodDescriptioncreateReview(AddCustomerReviewRequest request) Adds/creates a new review.voiddeleteReview(UUID reviewId) Deletes a review by id.editReview(ChangeCustomerReviewRequest changeCustomerReviewRequest) Changes a field/all fields of an existing review.findReviewById(UUID reviewId) Finds the customer review by id.findReviews(FindReviewRequest findReviewRequest) Finds the paginated reviews based on the request.
-
Method Details
-
findReviewById
Finds the customer review by id.- Parameters:
reviewId- the review id- Returns:
- the customer review found
- Throws:
com.dzidzi.exception.EntityNotFoundException- when review is not found
-
createReview
Adds/creates a new review.- Parameters:
request- theAddCustomerReviewRequestto create/add a new review- Returns:
- the newly created review
-
editReview
Changes a field/all fields of an existing review.- Parameters:
changeCustomerReviewRequest- theChangeCustomerReviewRequestcontaining the changes- Returns:
- the updated customer review
-
deleteReview
Deletes a review by id.- Parameters:
reviewId- the review id
-
findReviews
Finds the paginated reviews based on the request.- Parameters:
findReviewRequest- the request containing the params to filter reviews on- Returns:
- the
DzidziPaginationDTO
-