Class HvlNotificationPollingUserServiceImpl
java.lang.Object
tr.com.havelsan.javarch.notification.polling.starter.logic.HvlNotificationPollingUserServiceImpl
- All Implemented Interfaces:
HvlNotificationPollingUserService
@Service
public class HvlNotificationPollingUserServiceImpl
extends Object
implements HvlNotificationPollingUserService
The class which implements
HvlNotificationPollingUserService
.-
Constructor Summary
ConstructorDescriptionHvlNotificationPollingUserServiceImpl
(HvlNotificationPollingUserManager notificationPollingUserManager, HvlNotificationPollingUserOperationalManager notificationPollingUserOperationalManager) Instantiates a new HvlNotificationPollingUserService. -
Method Summary
Modifier and TypeMethodDescriptiongetNotificationList
(@NotNull @Valid HvlNotificationPollingUserQueryModel notificationPollingUserQueryMode) Gets notifications according to pollingNotificationQueryModeltr.com.havelsan.javarch.data.commons.pageable.HvlPage<HvlNotificationPollingUserModel>
getNotificationPage
(@NotNull @Valid HvlNotificationPollingUserQueryModel notificationPollingUserQueryModel) Gets notifications according to pollingNotificationQueryModelgetUnreadNotificationCount
(@NotBlank @Size(max=50) String assigneeUser) Gets unread notification count according to token ownergetUnreadNotificationCountByType
(@NotBlank @Size(max=50) String assigneeUser) Gets unread notification count by type.void
markAllRead
(@NotBlank @Size(max=50) String assigneeUser) Marks all unread notification as readvoid
markReadNotificationByUuid
(@NotBlank @Size(min=36,max=36) String uuid) Mark read notification by uuid.void
Removes notification according to expirationDatesendNotification
(@NotNull @Valid HvlNotificationPollingUserModel notificationPollingUserModel) Sends user specific notification
-
Constructor Details
-
HvlNotificationPollingUserServiceImpl
public HvlNotificationPollingUserServiceImpl(HvlNotificationPollingUserManager notificationPollingUserManager, HvlNotificationPollingUserOperationalManager notificationPollingUserOperationalManager) Instantiates a new HvlNotificationPollingUserService.- Parameters:
notificationPollingUserManager
- the notification polling user managernotificationPollingUserOperationalManager
- the notification polling user operational manager
-
-
Method Details
-
getUnreadNotificationCount
@Transactional(readOnly=true) public Integer getUnreadNotificationCount(@NotBlank @Size(max=50) @NotBlank @Size(max=50) String assigneeUser) Gets unread notification count according to token owner- Specified by:
getUnreadNotificationCount
in interfaceHvlNotificationPollingUserService
- Parameters:
assigneeUser
- the assignee user- Returns:
- unread notification count
-
getUnreadNotificationCountByType
@Transactional(readOnly=true) public HvlNotificationSubCountModel getUnreadNotificationCountByType(@NotBlank @Size(max=50) @NotBlank @Size(max=50) String assigneeUser) Gets unread notification count by type.- Specified by:
getUnreadNotificationCountByType
in interfaceHvlNotificationPollingUserService
- Parameters:
assigneeUser
- the assignee user- Returns:
- the unread notification count
-
markReadNotificationByUuid
public void markReadNotificationByUuid(@NotBlank @Size(min=36,max=36) @NotBlank @Size(min=36,max=36) String uuid) Mark read notification by uuid.- Specified by:
markReadNotificationByUuid
in interfaceHvlNotificationPollingUserService
- Parameters:
uuid
- the uuid
-
markAllRead
Marks all unread notification as read- Specified by:
markAllRead
in interfaceHvlNotificationPollingUserService
- Parameters:
assigneeUser
- the assignee user
-
sendNotification
public HvlNotificationPollingUserModel sendNotification(@NotNull @Valid @NotNull @Valid HvlNotificationPollingUserModel notificationPollingUserModel) Sends user specific notification- Specified by:
sendNotification
in interfaceHvlNotificationPollingUserService
- Parameters:
notificationPollingUserModel
- the notification polling user model- Returns:
- hvl notification polling user model
-
getNotificationPage
@Transactional(readOnly=true) @Validated(HvlNotificationPollingUserValidation.class) public tr.com.havelsan.javarch.data.commons.pageable.HvlPage<HvlNotificationPollingUserModel> getNotificationPage(@NotNull @Valid @NotNull @Valid HvlNotificationPollingUserQueryModel notificationPollingUserQueryModel) Gets notifications according to pollingNotificationQueryModel- Specified by:
getNotificationPage
in interfaceHvlNotificationPollingUserService
- Parameters:
notificationPollingUserQueryModel
- the notification polling user query model- Returns:
- notification page
-
getNotificationList
@Transactional(readOnly=true) @Validated(HvlNotificationPollingUserValidation.class) public List<HvlNotificationPollingUserModel> getNotificationList(@NotNull @Valid @NotNull @Valid HvlNotificationPollingUserQueryModel notificationPollingUserQueryMode) Gets notifications according to pollingNotificationQueryModel- Specified by:
getNotificationList
in interfaceHvlNotificationPollingUserService
- Parameters:
notificationPollingUserQueryMode
- the notification polling user query model- Returns:
- notification list
-
removeBulk
public void removeBulk()Removes notification according to expirationDate- Specified by:
removeBulk
in interfaceHvlNotificationPollingUserService
-