
com.plenigo.sdk.models.SubscriptionProduct Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of java-sdk Show documentation
Show all versions of java-sdk Show documentation
Java SDK wrapping plenigo REST-API for easier usage.
package com.plenigo.sdk.models;
import com.plenigo.sdk.internal.models.BaseProduct;
import com.plenigo.sdk.internal.util.DateUtils;
import java.util.Date;
/**
*
* Represents a subscription product.
*
*
* Thread safety: This class is thread safe and can be injected.
*
*/
public class SubscriptionProduct extends BaseProduct {
private Date endDate;
/**
* Required constructor.
*
* @param productId the id
* @param title the title
* @param buyDate the date the product was bought
* @param endDate the date the subscription expires
*/
public SubscriptionProduct(String productId, String title, Date buyDate, Date endDate) {
super(productId, title, buyDate);
this.endDate = DateUtils.copy(endDate);
}
/**
* Returns the date where the subscription expires.
*
* @return the end date
*/
public Date getEndDate() {
return DateUtils.copy(endDate);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy