module Safrano::NonMediaEntity
Public Instance Methods
metadata_h()
click to toggle source
non media entity metadata for json h
# File lib/odata/entity.rb, line 280 def metadata_h { uri: uri, type: type_name } end
odata_delete(req)
click to toggle source
# File lib/odata/entity.rb, line 289 def odata_delete(req) if req.accept?(APPJSON) # delete begin odata_delete_relation_and_entity(req, @navattr_reflection, @nav_parent) [200, EMPTY_HASH, [{ 'd' => req.service.get_emptycoll_odata_h }.to_json]] rescue SequelAdapterError => e BadRequestSequelAdapterError.new(e).odata_get(req) end else # TODO: other formats 415 end end
odata_media_value_get(_req)
click to toggle source
in case of a non media entity, we have to return an error on $value request
# File lib/odata/entity.rb, line 304 def odata_media_value_get(_req) BadRequestNonMediaValue.odata_get end
odata_media_value_put(_req)
click to toggle source
in case of a non media entity, we have to return an error on $value PUT
# File lib/odata/entity.rb, line 309 def odata_media_value_put(_req) BadRequestNonMediaValue.odata_get end
values_for_odata()
click to toggle source
# File lib/odata/entity.rb, line 285 def values_for_odata values end