net.sf.javaprinciples.resource.ResourcePutService Maven / Gradle / Ivy
package net.sf.javaprinciples.resource;
/**
* Service interface for PUT and POST operations for Resources.
* @author rvllewln
* @param Type of content in the Resource.
*
*/
public interface ResourcePutService
{
/**
* Put/Post a Resource.
* @param identifier The Resource's identifier (if known - typically null for a POST).
* @param resource The Resource representation to be stored/used.
* @return The ResourceIdentifier, which will be the same as that provided (for a PUT) or
* will be a new Identifier generated by the server for the Resource in the case of a POST.
* @throws ResourceException If there are any problems in putting the Resource.
*/
ResourceIdentifier putResource(ResourceIdentifier identifier, Resource resource) throws ResourceException;
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy