Class HitService
java.lang.Object
fr.paris.lutece.plugins.extend.modules.hit.service.HitService
- All Implemented Interfaces:
IHitService
HitService
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidCreates the a hit extender.findByParameters(String strIdExtendableResource, String strExtendableResourceType) Find by id extender.findByPrimaryKey(int nIdHit) Find.findByResourceList(List<String> listIdExtendableResource, String strExtendableResourceType) Find by list id extendable resource.findIdMostHitedResources(String strExtendableResourceType, int nItemsOffset, int nMaxItemsNumber) Get the ids of resources ordered by their number of hitsvoidincrementHit(Hit hit) Increment hit.voidremove(int nIdExtender) Removes a hit extender.voidremoveByResource(String strIdResource, String strResourceType) Removes a hit extender by id resource and resource type.voidUpdate a hit extender.
-
Field Details
-
BEAN_SERVICE
The Constant BEAN_SERVICE.- See Also:
-
-
Constructor Details
-
HitService
public HitService()
-
-
Method Details
-
create
Creates the a hit extender.- Specified by:
createin interfaceIHitService- Parameters:
hit- the hit
-
update
Update a hit extender.- Specified by:
updatein interfaceIHitService- Parameters:
hit- the hit
-
remove
public void remove(int nIdExtender) Removes a hit extender.- Specified by:
removein interfaceIHitService- Parameters:
nIdExtender- the n id hit
-
removeByResource
Removes a hit extender by id resource and resource type.- Specified by:
removeByResourcein interfaceIHitService- Parameters:
strIdResource- The id of the resource to removestrResourceType- The type of the resource to remove
-
incrementHit
Increment hit.- Specified by:
incrementHitin interfaceIHitService- Parameters:
hit- the hit
-
findByPrimaryKey
Find.- Specified by:
findByPrimaryKeyin interfaceIHitService- Parameters:
nIdHit- the n id extender- Returns:
- the hit
-
findByParameters
Find by id extender.- Specified by:
findByParametersin interfaceIHitService- Parameters:
strIdExtendableResource- the str id extendable resourcestrExtendableResourceType- the str extendable resource type- Returns:
- the hit
-
findIdMostHitedResources
public List<Integer> findIdMostHitedResources(String strExtendableResourceType, int nItemsOffset, int nMaxItemsNumber) Get the ids of resources ordered by their number of hits- Specified by:
findIdMostHitedResourcesin interfaceIHitService- Parameters:
strExtendableResourceType- The type of resources to considernItemsOffset- The offset of the items to get, or 0 to get items from the first onenMaxItemsNumber- The maximum number of items to return, or 0 to get every items- Returns:
- The list of ids of resources ordered by the number hits
-
findByResourceList
public List<Hit> findByResourceList(List<String> listIdExtendableResource, String strExtendableResourceType) Find by list id extendable resource.- Specified by:
findByResourceListin interfaceIHitService- Parameters:
listIdExtendableResource- the list of str id extendable resourcestrExtendableResourceType- the str extendable resource type- Returns:
- the hit list
-