Skip to content

Commit

Permalink
Add licensing fields
Browse files Browse the repository at this point in the history
  • Loading branch information
Jarkko-10Duke committed Jan 16, 2021
1 parent 3282cce commit 04d1efe
Show file tree
Hide file tree
Showing 4 changed files with 54 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
package com.tenduke.events.api.model.data;

import com.fasterxml.jackson.annotation.JsonInclude;

/**
* Event data fields for identifying a license anchor.
* @author jarkko
*/
@JsonInclude(JsonInclude.Include.NON_NULL)
public interface LicenseAnchorIdFields {

/**
* Gets the license anchor type.
* @return The license anchor object type name.
*/
String getLicenseAnchorType();

/**
* Gets identifier of the license anchor.
* @return The license anchor object id.
*/
String getLicenseAnchorId();
}
29 changes: 29 additions & 0 deletions src/main/java/com/tenduke/events/api/model/data/LicenseFields.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,38 @@ public interface LicenseFields {
*/
String getLicenseId();

/**
* The licensed item identifier.
* @return the licensed item id.
*/
String getLicensedItemId();

/**
* Unique id of entitlement that the license belongs to.
* @return the entitlement id.
*/
String getEntitlementId();

/**
* <p>
* Id of organization owning the license.
* </p>
* <p>
* License owner organization and license owner user are mutually exclusive,
* only one of them is set.
* </p>
* @return the organization id.
*/
String getLicenseOwnerOrganizationId();

/**
* <p>
* Id of user owning the license.
* </p>
* <p>
* License owner organization and license owner user are mutually exclusive,
* only one of them is set.
* </p>
*/
String getLicenseOwnerUserId();
}
Original file line number Diff line number Diff line change
Expand Up @@ -20,5 +20,5 @@ public interface LicenseLeaseFields extends LicenseFields {
* Gets the license anchors that a license can be tied to.
* @return the license anchors.
*/
List<Object> getLicenseAnchors();
List<LicenseAnchorIdFields> getLicenseAnchors();
}
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import com.fasterxml.jackson.annotation.JsonInclude;

/**
* Event data user id field.
* Event data user identification fields.
* @author jarkko
*/
@JsonInclude(JsonInclude.Include.NON_NULL)
Expand Down

0 comments on commit 04d1efe

Please sign in to comment.