View Javadoc

1   package com.atlassian.sal.api.license;
2   
3   import javax.annotation.Nullable;
4   
5   /**
6    * This event gets thrown whenever the host application license changes. This includes additions, updates, and removals.
7    *
8    * This event will get fired once per license key involved in a change; in other words, if multiple products are licensed
9    * from a single newly-added license key, only a single event would be fired.
10   *
11   * @since v3.0
12   */
13  public interface LicenseChangedEvent
14  {
15      /**
16       * Returns the previously set license. Will return null when adding a license.
17       *
18       * @return the previously set license.
19       */
20      @Nullable
21      BaseLicenseDetails getPreviousLicense();
22  
23      /**
24       * Returns the newly set license. Will return null when removing a license.
25       *
26       * @return the newly set license.
27       */
28      @Nullable
29      BaseLicenseDetails getNewLicense();
30  }