Class: ROM::HTTP::Relation
- Inherits:
-
Relation
- Object
- Relation
- ROM::HTTP::Relation
- Includes:
- Enumerable
- Defined in:
- lib/rom/http/relation.rb
Overview
HTTP-specific relation extensions
Instance Method Summary collapse
- #delete ⇒ Object
-
#initialize ⇒ Relation
constructor
private
A new instance of Relation.
- #insert(*args) ⇒ Object (also: #<<)
- #update(*args) ⇒ Object
Constructor Details
#initialize ⇒ Relation
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of Relation.
20 21 22 23 24 25 26 27 |
# File 'lib/rom/http/relation.rb', line 20 def initialize(*) super if schema? dataset.response_transformer( Dataset::ResponseTransformers::Schemad.new(schema.to_h) ) end end |
Instance Method Details
#delete ⇒ Object
41 42 43 |
# File 'lib/rom/http/relation.rb', line 41 def delete dataset.delete end |
#insert(*args) ⇒ Object Also known as: <<
30 31 32 |
# File 'lib/rom/http/relation.rb', line 30 def insert(*args) dataset.insert(*args) end |
#update(*args) ⇒ Object
36 37 38 |
# File 'lib/rom/http/relation.rb', line 36 def update(*args) dataset.update(*args) end |