Class WatchedThreadsRepositoryImpl
- java.lang.Object
-
- org.craftercms.commons.mongo.AbstractJongoRepository<WatchedThread>
-
- org.craftercms.social.repositories.system.notifications.impl.WatchedThreadsRepositoryImpl
-
- All Implemented Interfaces:
org.craftercms.commons.mongo.CrudRepository<WatchedThread>
,WatchedThreadsRepository
public class WatchedThreadsRepositoryImpl extends org.craftercms.commons.mongo.AbstractJongoRepository<WatchedThread> implements WatchedThreadsRepository
-
-
Constructor Summary
Constructors Constructor Description WatchedThreadsRepositoryImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addWatcher(String thread, String userId, String frequency)
Iterable<WatchedThread>
findAllWithWatchers()
List<ThreadsToNotify>
findProfilesToSend(String type)
List<Map>
findUserWatchedThreads(String profileId)
WatchedThread
isUserSubscribe(String threadId, String profileId)
void
removeWatcher(String thread, String userId)
-
Methods inherited from class org.craftercms.commons.mongo.AbstractJongoRepository
count, count, count, createSortQuery, deleteFile, deleteFile, find, find, findAll, findById, findByStringId, findOne, findOne, getCollection, getFileInfo, getFileInfo, getQueryFor, init, insert, insert, listFilesByName, readFile, readFile, remove, remove, removeById, removeByStringId, returnList, returnSimple, save, save, saveFile, saveFile, setJongo, setQueries, update, update, update, update, updateFile, updateFile, updateFile, validateObject, validateObject
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.craftercms.commons.mongo.CrudRepository
count, count, count, deleteFile, deleteFile, find, find, findAll, findById, findByStringId, findOne, findOne, getFileInfo, getFileInfo, insert, insert, listFilesByName, readFile, readFile, remove, remove, removeById, removeByStringId, save, save, saveFile, saveFile, update, update, update, update, updateFile, updateFile, updateFile
-
-
-
-
Method Detail
-
removeWatcher
public void removeWatcher(String thread, String userId) throws NotificationException
- Specified by:
removeWatcher
in interfaceWatchedThreadsRepository
- Throws:
NotificationException
-
addWatcher
public void addWatcher(String thread, String userId, String frequency) throws NotificationException
- Specified by:
addWatcher
in interfaceWatchedThreadsRepository
- Throws:
NotificationException
-
isUserSubscribe
public WatchedThread isUserSubscribe(String threadId, String profileId) throws org.craftercms.commons.mongo.MongoDataException
- Specified by:
isUserSubscribe
in interfaceWatchedThreadsRepository
- Throws:
org.craftercms.commons.mongo.MongoDataException
-
findAllWithWatchers
public Iterable<WatchedThread> findAllWithWatchers() throws NotificationException
- Specified by:
findAllWithWatchers
in interfaceWatchedThreadsRepository
- Throws:
NotificationException
-
findProfilesToSend
public List<ThreadsToNotify> findProfilesToSend(String type) throws NotificationException
- Specified by:
findProfilesToSend
in interfaceWatchedThreadsRepository
- Throws:
NotificationException
-
findUserWatchedThreads
public List<Map> findUserWatchedThreads(String profileId) throws SocialException
- Specified by:
findUserWatchedThreads
in interfaceWatchedThreadsRepository
- Throws:
SocialException
-
-