Class RatingHome


  • public class RatingHome
    extends java.lang.Object
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static Rating create​(Rating rating)
      Insert.
      static java.util.List<Rating> findByHistoryExtenderIds​(java.util.List<java.lang.Long> listIdHistory)
      Find a list Rating by history ids list
      static java.util.Optional<Rating> findByPrimaryKey​(int nIdRating)
      Load.
      static java.util.List<Rating> findByResource​(java.lang.String strIdExtendableResource, java.lang.String strExtendableResourceType)
      Select by resource.
      static java.util.List<Rating> findByResourceAndRatingType​(java.util.List<java.lang.String> listIdsResource, java.lang.String strExtendableResourceType, java.lang.String ratingType)
      Find a list Rating
      static java.util.Optional<Rating> findRating​(java.lang.String strIdExtendableResource, java.lang.String strExtendableResourceType, java.lang.String ratingType, double value, java.lang.String userGuid)
      load by primary key
      static java.util.List<Rating> findRatingByFilter​(RatingExtenderFilter filter)
      Find the list of rating
      static float[] findRatingValue​(java.util.List<java.lang.String> listIdResource, java.lang.String strExtendableResourceType, java.lang.String strRatingType)
      Find rating value of resource list
      static void remove​(int nIdRating)
      Delete.
      static void removeByIdExtenderHistory​(long nIdHistory)
      Delete By Id extender History.
      static void removeByListExtenderHistory​(java.util.List<java.lang.Long> listIdExtenderHistory)
      Delete By list Id extender History.
      static void removeByResource​(java.lang.String strIdExtendableResource, java.lang.String strExtendableResourceType)
      Delete by resource
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • create

        public static Rating create​(Rating rating)
        Insert.
        Parameters:
        rating - the rating
      • remove

        public static void remove​(int nIdRating)
        Delete.
        Parameters:
        nIdRating - the n id rating
      • removeByIdExtenderHistory

        public static void removeByIdExtenderHistory​(long nIdHistory)
        Delete By Id extender History.
        Parameters:
        nId - the Id extender History
      • removeByListExtenderHistory

        public static void removeByListExtenderHistory​(java.util.List<java.lang.Long> listIdExtenderHistory)
        Delete By list Id extender History.
        Parameters:
        listIdExtenderHistory - the list Id extender History
      • removeByResource

        public static void removeByResource​(java.lang.String strIdExtendableResource,
                                            java.lang.String strExtendableResourceType)
        Delete by resource
        Parameters:
        strIdExtendableResource - the Extendable resource id
        strExtendableResourceType - the Extendable Resourcer type
      • findByPrimaryKey

        public static java.util.Optional<Rating> findByPrimaryKey​(int nIdRating)
        Load.
        Parameters:
        nIdRating - the n id rating
        Returns:
        the rating
      • findRating

        public static java.util.Optional<Rating> findRating​(java.lang.String strIdExtendableResource,
                                                            java.lang.String strExtendableResourceType,
                                                            java.lang.String ratingType,
                                                            double value,
                                                            java.lang.String userGuid)
        load by primary key
        Parameters:
        strIdExtendableResource - the str id extendable resource
        strExtendableResourceType - the str extendable resource type
        ratingType - the rating type
        value - the rating value
        Returns:
        the rating
      • findByResource

        public static java.util.List<Rating> findByResource​(java.lang.String strIdExtendableResource,
                                                            java.lang.String strExtendableResourceType)
        Select by resource.
        Parameters:
        strIdExtendableResource - the str id extendable resource
        strExtendableResourceType - the str extendable resource type
        Returns:
        the rating list
      • findByResourceAndRatingType

        public static java.util.List<Rating> findByResourceAndRatingType​(java.util.List<java.lang.String> listIdsResource,
                                                                         java.lang.String strExtendableResourceType,
                                                                         java.lang.String ratingType)
        Find a list Rating
        Parameters:
        listResource - the list of extender resourceid
        plugin - the plugin
        Returns:
        the corresponding list Rating
      • findByHistoryExtenderIds

        public static java.util.List<Rating> findByHistoryExtenderIds​(java.util.List<java.lang.Long> listIdHistory)
        Find a list Rating by history ids list
        Parameters:
        listIdHistory - the list of history id
        plugin - the plugin
        Returns:
        the corresponding list Rating
      • findRatingValue

        public static float[] findRatingValue​(java.util.List<java.lang.String> listIdResource,
                                              java.lang.String strExtendableResourceType,
                                              java.lang.String strRatingType)
        Find rating value of resource list
        Parameters:
        listIdResource - the ids resource list
        strExtendableResourceType - the resource type
        strRatingType - the rating type
        Returns:
        array of rating value
      • findRatingByFilter

        public static java.util.List<Rating> findRatingByFilter​(RatingExtenderFilter filter)
        Find the list of rating
        Parameters:
        filter - the RatingExtenderFilter
        Returns:
        rating object list