Notification plugin

You can customize notification dates for a variety of types of notifications. Implement the INotificationPlugin plugin or modify the built-in implementation of this plugin. This plugin is responsible for determining the minimum lead time and maximum lead time for different types of notifications. The law frequently specifies these values, so define and calculate these numbers carefully.

For the methods in this plugin, the effective date is a method parameter. It specifies the date at which the action occurs. For example, suppose the lead time is 10 days if the effective date is prior to June 5, and 15 days if the effective date is June 5 or later. The plugin must return the value 10 for effective dates prior to June 5 and 15 for effective dates on or after June 5. This effective date argument is never null.

Another parameter is the line to jurisdictions mapping, using generics syntax this is Map<PolicyLinePattern, State[]>. This maps from a line of business to an array of jurisdictions. For example, imagine a commercial package policy with two lines: general liability and commercial property. The general liability line has only one jurisdiction (California) and the commercial property line has two jurisdictions (California and Arizona). In this case, the passed map contains two mappings.

  • One mapping from general liability to an array containing the single value of California
  • One mapping from commercial property to an array containing the values California and Arizona

Large commercial policies likely have much large mappings that could contain dozens of jurisdictions. This method parameter is never null and never empty. None of the mappings contain empty arrays of jurisdictions.

Refer to the built-in implementation of this plugin for a general pattern to use. Also, the built-in implementation of this plugin (gw.plugin.notification.impl.NotificationPlugin) has some utility functions that you can use to simplify your code. Specifically, look at the code for the method forAllLinesAndJurisdictions.

The built-in implementation of this plugin calculates the results based on looking up the input values in the system table NotificationConfig (controlled by the file notificationconfigs.xml).

If you write your own version of this plugin, you can use the notification system table or use completely different logic to calculate the lead time dates.

Notification by action type (minimum)

The first minimum lead time method has the following method signature.

int getMinimumLeadTime(Date effDate, Map<PolicyLinePattern, State[]> lineToJurisdictions,
                         NotificationActionType actionType) 

Notice that one of the parameters is a java.util.Map that maps a policy line pattern to an array of states. Using Gosu generics syntax, this is Map<PolicyLinePattern, State[]>. You must iterate across all the policy line patterns and the matching list of states and calculate the minimum lead time for all combinations of line of business and jurisdiction. Use the actionType typecode and effective date as appropriate. Your plugin method must return a value that represents the minimum lead time as a number of number of days.

The action type is an NotificationActionType typecode to indicate the type of notification for which PolicyCenter requests a date. A NotificationActionType includes typecodes such as those listed below.

  • fraudcancel – Notification requirements in days for cancellation due to fraud
  • rateincrease – Notification requirements in days for rate increases

The list of typecodes in this list is extensive. Refer to the typelist in Studio or the Data Dictionary for the complete list.

Notification by action type (maximum)

There is another method with identical method signature as the previously-mentioned method except the name is getMaximumLeadTime. That method must calculate the maximum lead time (not the minimum) for all combinations of line of business and jurisdiction.

int getMaximumLeadTime(Date effDate, Map<PolicyLinePattern, State[]> lineToJurisdictions,
                         NotificationActionType actionType) 

Notification by category (minimum)

Another variant of the getMinimumLeadTime method has the following method signature.

int getMaximumLeadTime(Date effDate, Map<PolicyLinePattern, State[]> lineToJurisdictions,
                         NotificationCategory category) throws RemoteException;

As you can see, it takes a notification category (NotificationCategory) instead of an action type.

The method uses the following notification category values in the built-in implementation.

  • cancel – Cancellation notification configurations
  • nonrenew – Non-renewal notification configurations
  • renewal – Renewal notification configurations

The plugin must return the number of days lead time that represents the minimum value for the lead time column. This must be the minimum value for all combinations of line of business and jurisdiction for the category and effective date.

Notification by category (maximum)

There is another method with identical method signature as the previously-mentioned method except that the name is getMaximumLeadTime. This method must calculate the maximum lead time (not the minimum) for all combinations of line of business and jurisdiction.

int getMaximumLeadTime(Date effDate, Map<PolicyLinePattern, State[]> lineToJurisdictions,
                         NotificationCategory category) throws RemoteException;