Class StarRating
java.lang.Object
fr.paris.lutece.plugins.extend.business.extender.history.ResourceExtenderHistory
fr.paris.lutece.plugins.extend.modules.rating.business.Rating
fr.paris.lutece.plugins.extend.modules.rating.business.StarRating
- All Implemented Interfaces:
fr.paris.lutece.plugins.extend.service.extender.facade.IExtendableResourceResult
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondoubleCalculate the score (min : 1 - max : 4).doubledoublegetTitle()Get tilte of the rating typeMethods inherited from class fr.paris.lutece.plugins.extend.modules.rating.business.Rating
getIdRating, getRatingCount, getRatingType, getRatingValue, getUser, setHistory, setIdRating, setRatingCount, setRatingType, setRatingValue, setScoreValue, setScoreValue, setUserMethods inherited from class fr.paris.lutece.plugins.extend.business.extender.history.ResourceExtenderHistory
getDateCreation, getExtendableResourceType, getExtenderType, getIdExtendableResource, getIdHistory, getIpAddress, getUserGuid, setDateCreation, setExtendableResourceType, setExtenderType, setIdExtendableResource, setIdHistory, setIpAddress, setUserGuidMethods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface fr.paris.lutece.plugins.extend.service.extender.facade.IExtendableResourceResult
getExtendableResourceType, getIdExtendableResource
-
Field Details
-
RATING_TITLE
- See Also:
-
-
Constructor Details
-
StarRating
public StarRating()
-
-
Method Details
-
getScoreValue
public double getScoreValue()- Overrides:
getScoreValuein classRating- Returns:
- the dScoreValue
-
getAverageScore
public double getAverageScore()Calculate the score (min : 1 - max : 4).- Returns:
- the average score
-
getAverageScoreRoundToHalf
public double getAverageScoreRoundToHalf()- Returns:
- the average score calculated with 0.5 precision
-
getTitle
Description copied from class:RatingGet tilte of the rating type
-