org.apache.olingo.server.api.etag

## Interface CustomETagSupport

- All Superinterfaces:
    OlingoExtension

      public interface CustomETagSupport
      extends OlingoExtension

  Processors that would like to support etags for certain entity sets can implement this interface.

  If implemented this interface can be registered at the ODataHttpHandler. This will result in change request to require an if-match/if-none-match or an if-modified-since/if-unmodified-since header. Otherwise the request will result in a "Precondition Required" response

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `hasETag(EdmBindingTarget entitySetOrSingleton)` This method will be called for update requests which target an entity or a property of an entity.
    `boolean` | `hasMediaETag(EdmBindingTarget entitySetOrSingleton)` This method will be called for update requests which target a media entity value.

- - ### Method Detail

    - #### hasETag

          boolean hasETag(EdmBindingTarget entitySetOrSingleton)

      This method will be called for update requests which target an entity or a property of an entity. If this method returns true and an header is not specified we will return a "Precondition Required" response. Validation has to be performed inside the processor methods after the dispatching. If this method returns false and an header is specified we will ignore the header.
      Parameters:
        `entitySetOrSingleton` -
      Returns:
        true if the entity set specified needs an if-match/if-none-match header

    - #### hasMediaETag

          boolean hasMediaETag(EdmBindingTarget entitySetOrSingleton)

      This method will be called for update requests which target a media entity value. If this method returns true and an header is not specified we will return a "Precondition Required" response. Validation has to be performed inside the processor methods after the dispatching. If this method returns false and an header is specified we will ignore the header.
      Parameters:
        `entitySetOrSingleton` -
      Returns:
        true if the entity set specified needs an if-match/if-none-match header

Copyright © 2013–2022 The Apache Software Foundation. All rights reserved.