
com.plenigo.sdk.models.ProductsBought 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 java.util.ArrayList;
import java.util.Collections;
import java.util.List;
/**
*
* This class contains information regarding the products that a user has bought.
*
*
* Thread safety: This class is thread safe and can be injected.
*
*/
public class ProductsBought {
private List subscriptionProducts;
private List singlePaymentProducts;
/**
* Required constructor.
*
* @param subscriptionProducts subscription products
* @param singlePaymentProducts single payment products
*/
public ProductsBought(List subscriptionProducts, List singlePaymentProducts) {
this.subscriptionProducts = new ArrayList();
if (subscriptionProducts != null) {
this.subscriptionProducts.addAll(subscriptionProducts);
}
this.singlePaymentProducts = new ArrayList();
if (singlePaymentProducts != null) {
this.singlePaymentProducts.addAll(singlePaymentProducts);
}
}
/**
* Returns the subscriptions an user has.
*
* @return the subscription products a user has
*/
public List getSubscriptionProducts() {
return Collections.unmodifiableList(subscriptionProducts);
}
/**
* Returns the single payment products an user has.
*
* @return the single payment products an user has
*/
public List getSinglePaymentProducts() {
return Collections.unmodifiableList(singlePaymentProducts);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy