fr.paris.lutece.plugins.rating.business
Class ResourceStatHome

java.lang.Object
  extended by fr.paris.lutece.plugins.rating.business.ResourceStatHome

public final class ResourceStatHome
extends java.lang.Object

class ResourceStatHome


Method Summary
static void create(ResourceStat resourceStat, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Creation of an instance of downloadStat
static ResourceStat findResourceStat(java.lang.String strResourceType, int nIdResource, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Returns an instance of ResourceStat whose resource type and resource identifier are specified in parameters
static int getDownloadCountByResource(java.lang.String strResourceType, int nIdResource, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Returns the count of resource download whose resource identifier and resource type are specified in parameters
static int getScore(java.lang.String strResourceType, int nIdResource, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Returns the score of a resource whose resource identifier and resource type are specified in parameters
static void remove(java.lang.String strResourceType, int nIdResource, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          Remove the ResourceStat whose identifier are specified in parameters
static void update(ResourceStat resourceStat, fr.paris.lutece.portal.service.plugin.Plugin plugin)
          update record in the table.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

create

public static void create(ResourceStat resourceStat,
                          fr.paris.lutece.portal.service.plugin.Plugin plugin)
Creation of an instance of downloadStat

Parameters:
resourceStat - The instance of the ResourceStat which contains the informations to store
plugin - the Plugin

update

public static void update(ResourceStat resourceStat,
                          fr.paris.lutece.portal.service.plugin.Plugin plugin)
update record in the table.

Parameters:
resourceStat - instance of the ResourceStat object to update
plugin - the plugin

remove

public static void remove(java.lang.String strResourceType,
                          int nIdResource,
                          fr.paris.lutece.portal.service.plugin.Plugin plugin)
Remove the ResourceStat whose identifier are specified in parameters

Parameters:
strResourceType - The type of the resource
nIdResource - the id of the resource
plugin - the Plugin

findResourceStat

public static ResourceStat findResourceStat(java.lang.String strResourceType,
                                            int nIdResource,
                                            fr.paris.lutece.portal.service.plugin.Plugin plugin)
Returns an instance of ResourceStat whose resource type and resource identifier are specified in parameters

Parameters:
strResourceType - The type of the resource
nIdResource - the id of the resource
plugin - the Plugin
Returns:
an instance of ResourceStat

getDownloadCountByResource

public static int getDownloadCountByResource(java.lang.String strResourceType,
                                             int nIdResource,
                                             fr.paris.lutece.portal.service.plugin.Plugin plugin)
Returns the count of resource download whose resource identifier and resource type are specified in parameters

Parameters:
strResourceType - The type of the resource
nIdResource - the id of the resource
plugin - the Plugin
Returns:
the count of resource download

getScore

public static int getScore(java.lang.String strResourceType,
                           int nIdResource,
                           fr.paris.lutece.portal.service.plugin.Plugin plugin)
Returns the score of a resource whose resource identifier and resource type are specified in parameters

Parameters:
strResourceType - The type of the resource
nIdResource - the id of the resource
plugin - the Plugin
Returns:
the score


Copyright © 2011 Mairie de Paris. All Rights Reserved.