public class RatingRequestBody extends FeedbackRequestBody
RatingRequestBody provides a structure for passing star rating as a request body over a REST API.
  • Constructor Details

    • RatingRequestBody

      public RatingRequestBody()
      Default constructor
    • RatingRequestBody

      public RatingRequestBody(RatingRequestBody template)
      Copy/clone constructor
      Parameters:
      template - object to copy
  • Method Details

    • getStarRating

      public StarRating getStarRating()
      Return the star rating.
      Returns:
      enum
    • setStarRating

      public void setStarRating(StarRating starRating)
      Set up the star rating.
      Parameters:
      starRating - enum
    • getReview

      public String getReview()
      Return the attached review (if any)
      Returns:
      text
    • setReview

      public void setReview(String review)
      Set up the attached review (if any)
      Parameters:
      review - text
    • toString

      public String toString()
      JSON-style toString.
      Overrides:
      toString in class FeedbackRequestBody
      Returns:
      list of properties and their values.
    • equals

      public boolean equals(Object objectToCompare)
      Equals method that returns true if containing properties are the same.
      Overrides:
      equals in class FeedbackRequestBody
      Parameters:
      objectToCompare - object to compare
      Returns:
      boolean result of comparison
    • hashCode

      public int hashCode()
      Return hash code for this object
      Overrides:
      hashCode in class FeedbackRequestBody
      Returns:
      int hash code