ravenx v0.1.0 Ravenx.Notification

Base module for notifications implemented using Ravenx strategies.

Summary

Functions

Function used to send a notification asynchronously using a list with the configuration of the notification

Function used to send a notification synchronously using a list with the configuration of the notification

Macros

Macro to inject notification features in application’s modules

Functions

dispatch_async_notification(notification)
dispatch_async_notification(list) :: {atom, any}

Function used to send a notification asynchronously using a list with the configuration of the notification.

The list should have this objects:

  1. Strategy atom: defining which strategy to use
  2. Payload map: including the payload data of the notification.
  3. Options map (optional): the special configuration of the notification

It will respond with a tuple, indicating if everything is :ok or there was an :error.

dispatch_notification(notification)
dispatch_notification(list) :: {atom, any}

Function used to send a notification synchronously using a list with the configuration of the notification.

The list should have this objects:

  1. Strategy atom: defining which strategy to use
  2. Payload map: including the payload data of the notification.
  3. Options map (optional): the special configuration of the notification

It will respond with a tuple, indicating if everything was :ok or there was an :error.

Macros

__using__()

Macro to inject notification features in application’s modules.