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

io.sphere.sdk.orders.queries.OrderQuery Maven / Gradle / Ivy

There is a newer version: 1.0.0-M26
Show newest version
package io.sphere.sdk.orders.queries;

import com.fasterxml.jackson.core.type.TypeReference;
import io.sphere.sdk.orders.Order;
import io.sphere.sdk.orders.expansion.OrderExpansionModel;
import io.sphere.sdk.queries.PagedQueryResult;
import io.sphere.sdk.queries.MetaModelQueryDsl;

/**
 {@doc.gen summary orders}
 */
public interface OrderQuery extends MetaModelQueryDsl> {
    static OrderQuery of() {
        return new OrderQueryImpl();
    }

    static TypeReference> resultTypeReference() {
        return new TypeReference>(){
            @Override
            public String toString() {
                return "TypeReference>";
            }
        };
    }

    default OrderQuery byCustomerId(final String customerId) {
        return withPredicates(m -> m.customerId().is(customerId));
    }

    default OrderQuery byCustomerEmail(final String customerEmail) {
        return withPredicates(m -> m.customerEmail().is(customerEmail));
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy