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

io.sphere.sdk.customobjects.queries.CustomObjectQueryModel Maven / Gradle / Ivy

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

import io.sphere.sdk.customobjects.CustomObject;
import io.sphere.sdk.queries.DefaultModelQueryModelImpl;
import io.sphere.sdk.queries.QueryModel;
import io.sphere.sdk.queries.StringQuerySortingModel;

import java.util.Optional;

/**
 * Metamodel to explore for which fields can be queried in a {@link io.sphere.sdk.customobjects.CustomObject}.
 * @param  The type of the value of the custom object.
 */
public class CustomObjectQueryModel extends DefaultModelQueryModelImpl> {

    static  CustomObjectQueryModel get() {
        return new CustomObjectQueryModel<>(Optional.>>empty(), Optional.empty());
    }

    private CustomObjectQueryModel(final Optional>> parent, final Optional pathSegment) {
        super(parent, pathSegment);
    }

    public StringQuerySortingModel> container() {
        return new StringQuerySortingModel<>(Optional.of(this), "container");
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy