> + private final Date endTime;
> +
> + @ConstructorProperties({
> + "amount", "discount_amount", "discount_percent", "period", "price",
> "resource", "start_time", "end_time"
> + })
> + public CalcSubscription(@Nullable Double amount, @Nullable Double
> discountAmount, @Nullable Double discountPercent,
> + @Nullable String period, @Nullable Double price,
> SubscriptionResource resource,
> + @Nullable Date startTime, @Nullable Date endTime)
> {
> + checkArgument(!(endTime == null && period == null),
> + "Subscription period should be configured with endTime or
> period");
> + this.amount = amount;
> + this.discountAmount = discountAmount;
> + this.discountPercent = discountPercent;
> + this.period = period;
> + this.price = price;
> + this.resource = checkNotNull(resource);
`checkNotNull(resource, "resource");`
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-labs/pull/41/files#r8002439