Class NotificationService


  • public class NotificationService
    extends Object
    NotificationService
    • Method Detail

      • findByPrimaryKey

        public Notification findByPrimaryKey​(int nIdNotification)
        Find the notification by its primary key
        Parameters:
        nIdNotification - the id notification
        Returns:
        a Notification
      • create

        public int create​(Notification notification)
        Create a notification
        Parameters:
        notification - the notification
        Returns:
        the newly created notification id
      • update

        public void update​(Notification notification)
        Update the notification
        Parameters:
        notification - the notification
      • remove

        public void remove​(int nIdNotification)
        Remove the notification
        Parameters:
        nIdNotification - the id notification
      • removeByIdDemand

        public void removeByIdDemand​(int nIdDemand)
        Remove the notifications from a given ID demand
        Parameters:
        nIdDemand - the id demand
      • getNumberUnreadNotifications

        public int getNumberUnreadNotifications​(int nIdDemand)
        Get the number of unread notifications of a demand
        Parameters:
        nIdDemand - the id demand
        Returns:
        the number of unread notifications
      • getNumberNotifications

        public int getNumberNotifications​(int nIdDemand)
        Get the number of notifications of a demand
        Parameters:
        nIdDemand - the id demand
        Returns:
        the number of notifications