Interface NotificationMessageProvider<T>

All Superinterfaces:
java.util.function.Function<java.lang.String,​NotificationMessage<T>>
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface
public interface NotificationMessageProvider<T>
extends java.util.function.Function<java.lang.String,​NotificationMessage<T>>
Provider of NotificationMessage(s) that can be used for creating the notifications
Author:
Filip Hrisafov
  • Method Summary

    Modifier and Type Method Description
    default NotificationMessage<T> apply​(java.lang.String deliverer)  
    NotificationMessage<T> createMessage​(java.lang.String deliverer)
    Create a notification message for the provided deliverer

    Methods inherited from interface java.util.function.Function

    andThen, compose
  • Method Details

    • apply

      default NotificationMessage<T> apply​(java.lang.String deliverer)
      Specified by:
      apply in interface java.util.function.Function<java.lang.String,​NotificationMessage<T>>
    • createMessage

      NotificationMessage<T> createMessage​(java.lang.String deliverer)
      Create a notification message for the provided deliverer
      Parameters:
      deliverer - the type of the deliverer that will consume the message
      Returns:
      the notification message that can be consumed by the deliverer