fr.paris.lutece.plugins.stock.modules.tickets.business
Class ProductStatisticDAO

java.lang.Object
  extended by fr.paris.lutece.util.jpa.JPAGenericDAO<K,E>
      extended by fr.paris.lutece.portal.service.jpa.JPALuteceDAO<K,E>
          extended by fr.paris.lutece.plugins.stock.commons.dao.AbstractStockDAO<java.lang.Integer,ProductStatistic>
              extended by fr.paris.lutece.plugins.stock.modules.tickets.business.ProductStatisticDAO
All Implemented Interfaces:
IProductStatisticDAO, fr.paris.lutece.util.jpa.IGenericDAO<java.lang.Integer,ProductStatistic>

public final class ProductStatisticDAO
extends fr.paris.lutece.plugins.stock.commons.dao.AbstractStockDAO<java.lang.Integer,ProductStatistic>
implements IProductStatisticDAO

This class provides Data Access methods for Person objects


Constructor Summary
ProductStatisticDAO()
           
 
Method Summary
 java.util.List<ProductStatistic> getAllByIdProduct(java.lang.Integer idProduct)
          get all ProductStatistic by the product identifier
 java.util.List<ResultStatistic> getAllResultStatisticByParameters(java.lang.String strTimesUnit, java.lang.String strDateDebut, java.lang.String strDateFin)
          get all association of date and products count by parameters
 java.lang.Integer getCountProductsByDates(java.lang.String strDateDebut, java.lang.String strDateFin)
          get the purchase count by dates parameters
 java.lang.String getPluginName()
          
 
Methods inherited from class fr.paris.lutece.plugins.stock.commons.dao.AbstractStockDAO
addRestriction, createPagedQuery, findAll
 
Methods inherited from class fr.paris.lutece.portal.service.jpa.JPALuteceDAO
createNativeQuery, getEntityManagerFactory
 
Methods inherited from class fr.paris.lutece.util.jpa.JPAGenericDAO
create, detach, findAll, findById, flush, getEM, getEntityClass, getEntityClassName, remove, update
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface fr.paris.lutece.util.jpa.IGenericDAO
create, detach, findAll, findById, flush, remove, update
 

Constructor Detail

ProductStatisticDAO

public ProductStatisticDAO()
Method Detail

getPluginName

public java.lang.String getPluginName()

Specified by:
getPluginName in class fr.paris.lutece.portal.service.jpa.JPALuteceDAO<java.lang.Integer,ProductStatistic>

getAllByIdProduct

public java.util.List<ProductStatistic> getAllByIdProduct(java.lang.Integer idProduct)
get all ProductStatistic by the product identifier

Specified by:
getAllByIdProduct in interface IProductStatisticDAO
Parameters:
idProduct - the identifier of product
Returns:
a list of ProductStatistic instance

getAllResultStatisticByParameters

public java.util.List<ResultStatistic> getAllResultStatisticByParameters(java.lang.String strTimesUnit,
                                                                         java.lang.String strDateDebut,
                                                                         java.lang.String strDateFin)
get all association of date and products count by parameters

Specified by:
getAllResultStatisticByParameters in interface IProductStatisticDAO
Parameters:
strTimesUnit - the times unit
strDateDebut - the begin date
strDateFin - the end date
Returns:
a list of ResultStatistic

getCountProductsByDates

public java.lang.Integer getCountProductsByDates(java.lang.String strDateDebut,
                                                 java.lang.String strDateFin)
get the purchase count by dates parameters

Specified by:
getCountProductsByDates in interface IProductStatisticDAO
Parameters:
strDateDebut - the date begin
strDateFin - the date end
Returns:
the purchase count


Copyright © 2012 Mairie de Paris. All Rights Reserved.