All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.sphere.sdk.cartdiscounts.DiscountedLineItemPortion Maven / Gradle / Ivy

There is a newer version: 2.16.0
Show newest version
package io.sphere.sdk.cartdiscounts;

import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import io.sphere.sdk.models.Reference;
import io.sphere.sdk.models.Referenceable;

import javax.money.MonetaryAmount;

@JsonDeserialize(as = DiscountedLineItemPortionImpl.class)
public interface DiscountedLineItemPortion {
    static DiscountedLineItemPortion of(final Referenceable discount, final MonetaryAmount discountedAmount) {
        return new DiscountedLineItemPortionImpl(discount.toReference(), discountedAmount);
    }

    Reference getDiscount();

    MonetaryAmount getDiscountedAmount();
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy