public class ProductDAO extends fr.paris.lutece.plugins.stock.commons.dao.AbstractStockDAO<Integer,Product> implements IProductDAO
Product objects.| Constructor and Description |
|---|
ProductDAO() |
| Modifier and Type | Method and Description |
|---|---|
List<Product> |
findByFilter(ProductFilter filter)
Find product list by filter.
|
fr.paris.lutece.plugins.stock.commons.ResultList<Product> |
findByFilter(ProductFilter filter,
fr.paris.lutece.plugins.stock.commons.dao.PaginationProperties paginationProperties)
Finds by filter.
|
List<Product> |
getAllByName(String name)
Returns products by name
|
Integer |
getCountProductALAfficheByDate(String strDate)
Return the number of current product
|
Integer |
getCountProductAVenirByDate(String strDate)
Return the number of future product
|
String |
getPluginName() |
List<Integer> |
getProductsIdsForTaskTimed(String keyDate,
Timestamp timestampStart,
Timestamp timestampEnd)
Returns products IDs between two timestamps
|
Boolean |
isFull(Integer productId)
Check if product is ful
|
Boolean |
isType(Integer productId,
Integer genreId)
Check if product is type of representation
|
Boolean |
isTypeOffer(Integer productId,
Integer genreId,
String keyDate,
Timestamp now,
String annuleKey) |
getEntityManagerFactorycreate, detach, findAll, findById, flush, getEM, getEntityClass, getEntityClassName, remove, updatepublic String getPluginName()
public List<Product> findByFilter(ProductFilter filter)
findByFilter in interface IProductDAOfilter - the filterpublic fr.paris.lutece.plugins.stock.commons.ResultList<Product> findByFilter(ProductFilter filter, fr.paris.lutece.plugins.stock.commons.dao.PaginationProperties paginationProperties)
findByFilter in interface IProductDAOfilter - the filterpaginationProperties - the pagination propertiespublic List<Product> getAllByName(String name)
getAllByName in interface IProductDAOname - product namepublic Integer getCountProductALAfficheByDate(String strDate)
getCountProductALAfficheByDate in interface IProductDAOstrDate - the current datepublic Integer getCountProductAVenirByDate(String strDate)
getCountProductAVenirByDate in interface IProductDAOstrDate - the current datepublic Boolean isFull(Integer productId)
isFull in interface IProductDAOproductId - the product idpublic Boolean isType(Integer productId, Integer genreId)
isType in interface IProductDAOgenreId - the genre to checkpublic Boolean isTypeOffer(Integer productId, Integer genreId, String keyDate, Timestamp now, String annuleKey)
isTypeOffer in interface IProductDAOpublic List<Integer> getProductsIdsForTaskTimed(String keyDate, Timestamp timestampStart, Timestamp timestampEnd)
getProductsIdsForTaskTimed in interface IProductDAOkeyDate - the attribute keytimestampStart - the start timestamptimestamsEnd - the end timestampCopyright © 2023 City of Paris. All rights reserved.