Class: ROM::HTTP::Relation

Inherits:
Relation
  • Object
show all
Includes:
Enumerable
Defined in:
lib/rom/http/relation.rb

Overview

HTTP-specific relation extensions

Instance Method Summary collapse

Constructor Details

#initializeRelation

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

#deleteObject

See Also:



41
42
43
# File 'lib/rom/http/relation.rb', line 41

def delete
  dataset.delete
end

#insert(*args) ⇒ Object Also known as: <<

See Also:



30
31
32
# File 'lib/rom/http/relation.rb', line 30

def insert(*args)
  dataset.insert(*args)
end

#update(*args) ⇒ Object

See Also:



36
37
38
# File 'lib/rom/http/relation.rb', line 36

def update(*args)
  dataset.update(*args)
end