anchor.diff:  %% @end
   %%--------------------------------------------------------------------
   -spec get_cdmi_capability(cowboy_req:req(), cdmi_req()) ->
  -    {binary(), cowboy_req:req(), cdmi_req()}.
  +    {term(), cowboy_req:req(), cdmi_req()}.
   get_cdmi_capability(Req, #cdmi_req{
       resource = {capabilities, CapType},
       options = Options
  
positive.code:     {?DATAOBJECT_CAPABILITY_ID, filename:absname(<<"/", (?DATAOBJECT_CAPABILITY_PATH)/binary>>)}
  ]).
  
  
  %%%===================================================================
  %%% API
  
negative.code:     {json_utils:encode(Capabilities), Req, CdmiReq}.
  
  
  %%--------------------------------------------------------------------
  %% @doc Cowboy callback function (as content_types_provided).
  %% Returns requested info about specified directory (container).
  %% @end
  %%--------------------------------------------------------------------
  -spec get_cdmi_container(cowboy_req:req(), cdmi_req()) ->
      {term(), cowboy_req:req(), cdmi_req()}.
  get_cdmi_container(Req, CdmiReq) ->
      ?run_cdmi(Req, CdmiReq, cdmi_container:get_cdmi(Req, CdmiReq)).
  
  
  -spec get_cdmi_dataobject(cowboy_req:req(), cdmi_req()) ->
      {term(), cowboy_req:req(), cdmi_req()}.
  get_cdmi_dataobject(_, _) ->
      ok.
  
  
  -spec get_binary_dataobject(cowboy_req:req(), cdmi_req()) ->
      {term(), cowboy_req:req(), cdmi_req()}.
  get_binary_dataobject(_, _) ->
      ok.
  
  
  %%--------------------------------------------------------------------
  %% @doc Cowboy callback function (as content_types_provided).
  %% Creates, moves, copies or updates directory (container).
  %% @end
  %%--------------------------------------------------------------------
  -spec put_cdmi_container(cowboy_req:req(), cdmi_req()) ->
      {term(), cowboy_req:req(), cdmi_req()}.
  put_cdmi_container(Req, CdmiReq) ->
      ?run_cdmi(Req, CdmiReq, cdmi_container:put_cdmi(Req, CdmiReq)).
  
  
  %%--------------------------------------------------------------------
  %% @doc Cowboy callback function (as content_types_provided).
  %% Creates directory (container).
  %% @end
  %%--------------------------------------------------------------------
  -spec put_binary_container(cowboy_req:req(), cdmi_req()) ->
      {term(), cowboy_req:req(), cdmi_req()}.
  put_binary_container(Req, CdmiReq) ->
      ?run_cdmi(Req, CdmiReq, cdmi_container:put_binary(Req, CdmiReq)).
  
  
  -spec put_cdmi_dataobject(cowboy_req:req(), cdmi_req()) ->
      {term(), cowboy_req:req(), cdmi_req()}.
  put_cdmi_dataobject(_, _) ->
      ok.
  
  
  -spec put_binary_dataobject(cowboy_req:req(), cdmi_req()) ->
      {term(), cowboy_req:req(), cdmi_req()}.
  put_binary_dataobject(_, _) ->
      ok.
  
  
  %%--------------------------------------------------------------------
  %% @doc Cowboy callback function.
  %% Deletes specified resource (container or dataobject).
  %% @end
  %%--------------------------------------------------------------------
  -spec delete_resource(cowboy_req:req(), cdmi_req()) ->
      {term(), cowboy_req:req(), cdmi_req()}.
  delete_resource(Req, #cdmi_req{resource = container} = CdmiReq) ->
      ?run_cdmi(Req, CdmiReq, cdmi_container:delete_cdmi(Req, CdmiReq));
  delete_resource(Req, #cdmi_req{resource = dataobject} = CdmiReq) ->
      ok.
  
  
  