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

io.sphere.client.shop.CustomObjectService Maven / Gradle / Ivy

package io.sphere.client.shop;

import io.sphere.client.CommandRequest;
import io.sphere.client.DeleteRequest;
import io.sphere.client.FetchRequest;
import io.sphere.client.model.CustomObject;

/** Sphere HTTP API for working with custom objects. */
public interface CustomObjectService {
    /**
     * Finds a custom object by container and key.
     */
    FetchRequest get(String container, String key);

    /**
     * Sets the custom object identified by container and key
     *
     * Will overwrite all data that already exists under that key.
     */
     CommandRequest set(String container, String key, T value);

    /**
     * Sets the custom object identified by container and key
     *
     * Will overwrite all data that already exists under that key. Fails with ConcurrentModification error if the version
     * of the existing object does not match the given version.
     */
     CommandRequest set(String container, String key, T value, int version);

    /**
     *
     * Deletes the object identified by container and key.
     */
    DeleteRequest delete(String container, String key);
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy