Class AuthorizationEventUtil

java.lang.Object
com.skava.auth.util.AuthorizationEventUtil

public final class AuthorizationEventUtil extends Object
Author:
Infosys Equinox
  • Method Details

    • sendingNotificationForRole

      public static <T> void sendingNotificationForRole(com.skava.core.event.EventClientComponent eventClientComponent, com.skava.core.event.Message<T> authMessage, String routingKey, Collection collection, long storeId)
      This method is used to send Notification to user if any user or client roles added or updated. This will send an event to Notification services through message queue.
      Type Parameters:
      T - type of the event PayLoad.
      Parameters:
      eventClientComponent - Holds EventClientComponent object which is used send event to topic which is used to send notification.
      authMessage - Holds Message object which contains payload details.
      routingKey - Indicates the routing key of the event triggered.
      collection - Holds Collection object which is used to get collection id and business id for events.
      storeId - Indicates the store id.
    • buildEventData

      public static void buildEventData(com.skava.core.event.EventClientComponent eventClientComponent, List<UserRolesVO> userroles, CollectionVO collectionVO, String authToken, long storeId)
      This method used to build event data
      Parameters:
      eventClientComponent - the eventClientComponent
      userroles - the userroles
      collectionVO - the collectionVO
      authToken - token of the user who adds the roles to the user.
      storeId - the storeId
    • buildClientEventData

      public static void buildClientEventData(com.skava.core.event.EventClientComponent eventClientComponent, List<ClientRolesVO> clientroles, CollectionVO collectionVO, String authToken, long storeId)
      This method used to build event data
      Parameters:
      eventClientComponent - eventClientComponent
      clientroles - the clientroles
      collectionVO - the collectionVO
      authToken - token of the user who adds the roles to the user.
      storeId - the storeId
    • buildEventData

      public static void buildEventData(com.skava.core.event.EventClientComponent eventClientComponent, List<UserRolesVO> addedUserroles, List<UserRolesVO> removedUserroles, List<UserRolesVO> updatedUserRoles, Collection collection, String authToken, long storeId)
      This method used to build event data
      Parameters:
      eventClientComponent - eventClientComponent
      addedUserroles - addedUserroles
      removedUserroles - removedUserroles
      updatedUserRoles - updatedUserRoles
      collection - collection
      authToken - token of the user who adds the roles to the user.
      storeId - storeId
    • buildClientEventData

      public static void buildClientEventData(com.skava.core.event.EventClientComponent eventClientComponent, List<ClientRolesVO> addedClientroles, List<ClientRolesVO> removedClientroles, List<ClientRolesVO> updatedClientRoles, Collection collection, String authToken, long storeId)
      This method used to build event data
      Parameters:
      eventClientComponent - eventClientComponent
      addedClientroles - addedClientroles
      removedClientroles - removedClientroles
      updatedClientRoles - updatedClientRoles
      collection - collection
      authToken - token of the user who adds the roles to the user.
      storeId - storeId