@Repository public class PushDaoImpl extends Object implements PushDao
Push
objectsConstructor and Description |
---|
PushDaoImpl()
Creates a new instance of a
PushDaoImpl |
Modifier and Type | Method and Description |
---|---|
int |
countPushes()
Returns the number of
Push messages persisted. |
List<Push> |
findAllPush()
Returns a list of ALL the
Push messages
that are persisted.WARNING: This method can return A LOT of data |
List<Device> |
findDevicesForPush(Push push)
Finds the devices a push message was sent too
|
Push |
findPushById(Long id)
Finds a
Push by its ID. |
List<PushDeviceTuple> |
findUnsentPushTuples()
Finds push notifications that has to be sent
|
javax.persistence.EntityManager |
getEntityManager() |
PushDeviceTupleService |
getPdtService() |
boolean |
removePush(Push push)
Removes a
Push instance. |
void |
savePush(Push push)
Persists a
Push instance. |
void |
savePush(Push push,
List<Device> devices)
Persists a
Push instance and creates PushDeviceTuple
instances for each of the specified devices. |
void |
savePushDeviceTuples(List<PushDeviceTuple> tuples) |
void |
setEntityManager(javax.persistence.EntityManager entityManager) |
void |
setPdtService(PushDeviceTupleService pdtService) |
public PushDaoImpl()
PushDaoImpl
public Push findPushById(Long id)
PushDao
Push
by its ID.findPushById
in interface PushDao
id
- ID of the Push
to find.Push
that has the specified ID.public List<Push> findAllPush()
PushDao
Push
messages
that are persisted.findAllPush
in interface PushDao
Push
messages.public int countPushes()
PushDao
Push
messages persisted.countPushes
in interface PushDao
Push
messages persisted.public List<PushDeviceTuple> findUnsentPushTuples()
PushDao
findUnsentPushTuples
in interface PushDao
PushDeviceTuple
entries that has to be sent.@Transactional public void savePush(Push push)
PushDao
Push
instance.@Transactional public boolean removePush(Push push)
PushDao
Push
instance.removePush
in interface PushDao
@Transactional public void savePush(Push push, List<Device> devices)
PushDao
Push
instance and creates PushDeviceTuple
instances for each of the specified devices.@Transactional public List<Device> findDevicesForPush(Push push)
PushDao
findDevicesForPush
in interface PushDao
push
- Push
message to find devices of.@Transactional public void savePushDeviceTuples(List<PushDeviceTuple> tuples)
public javax.persistence.EntityManager getEntityManager()
public void setEntityManager(javax.persistence.EntityManager entityManager)
public PushDeviceTupleService getPdtService()
public void setPdtService(PushDeviceTupleService pdtService)
pdtService
- the pdtService to setCopyright © 2011-2013 The Kuali Foundation. All Rights Reserved.