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

io.sphere.sdk.carts.expansion.CustomLineItemExpansionModelImpl Maven / Gradle / Ivy

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

import io.sphere.sdk.expansion.ExpansionModelImpl;

import java.util.List;

final class CustomLineItemExpansionModelImpl extends ExpansionModelImpl implements CustomLineItemExpansionModel {
    CustomLineItemExpansionModelImpl(final List parentPath, final String path) {
        super(parentPath, path);
    }

    @Override
    public DiscountedLineItemPricePerQuantityExpansionModel discountedPricePerQuantity() {
        return discountedPricePerQuantity("*");
    }

    @Override
    public DiscountedLineItemPricePerQuantityExpansionModel discountedPricePerQuantity(final int index) {
        return discountedPricePerQuantity("" + index);
    }

    private DiscountedLineItemPricePerQuantityExpansionModel discountedPricePerQuantity(final String s) {
        return new DiscountedLineItemPricePerQuantityExpansionModelImpl<>(pathExpression(), "discountedPricePerQuantity[" + s + "]");
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy