java.lang.Object
org.odpi.openmetadata.viewservices.feedbackmanager.properties.RatingProperties

public class RatingProperties extends Object
RatingProperties stores information about a rating connected to an asset. Ratings provide informal feedback on the quality of assets and can be added at any time.

Ratings have the userId of the person who added it, a star rating and an optional review comment.

The content of the rating is a personal judgement (which is why the user's id is in the object) and there is no formal review of the ratings. However, they can be used as a basis for crowd-sourcing feedback to asset owners.
  • Constructor Summary

    Constructors
    Constructor
    Description
    Default constructor
    Copy/clone constructor.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    equals(Object objectToCompare)
    Compare the values of the supplied object with those stored in the current object.
    Return the review comments - null means no review is available.
    org.odpi.openmetadata.frameworks.openmetadata.enums.StarRating
    Return the stars for the rating.
    int
    Return hash code for this object
    void
    setReview(String review)
    Set up the review comments - null means no review is available.
    void
    setStarRating(org.odpi.openmetadata.frameworks.openmetadata.enums.StarRating starRating)
    Set up the stars for the rating.
    Standard toString method.

    Methods inherited from class java.lang.Object

    getClass, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • RatingProperties

      public RatingProperties()
      Default constructor
    • RatingProperties

      public RatingProperties(RatingProperties template)
      Copy/clone constructor.
      Parameters:
      template - element to copy
  • Method Details

    • getStarRating

      public org.odpi.openmetadata.frameworks.openmetadata.enums.StarRating getStarRating()
      Return the stars for the rating.
      Returns:
      StarRating enum
    • setStarRating

      public void setStarRating(org.odpi.openmetadata.frameworks.openmetadata.enums.StarRating starRating)
      Set up the stars for the rating.
      Parameters:
      starRating - StarRating enum
    • getReview

      public String getReview()
      Return the review comments - null means no review is available.
      Returns:
      String review comments
    • setReview

      public void setReview(String review)
      Set up the review comments - null means no review is available.
      Parameters:
      review - String review comments
    • toString

      public String toString()
      Standard toString method.
      Overrides:
      toString in class Object
      Returns:
      print out of variables in a JSON-style
    • equals

      public boolean equals(Object objectToCompare)
      Compare the values of the supplied object with those stored in the current object.
      Overrides:
      equals in class Object
      Parameters:
      objectToCompare - supplied object
      Returns:
      boolean result of comparison
    • hashCode

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