Class: Riddl::Utils::Notifications::Producer::Subscription

Inherits:
Implementation
  • Object
show all
Defined in:
lib/ruby/riddl/utils/notifications_producer.rb

Overview

}}}

Instance Method Summary collapse

Methods inherited from Implementation

#headers, #initialize, #status

Constructor Details

This class inherits a constructor from Riddl::Implementation

Instance Method Details

#responseObject

{{{



209
210
211
212
213
214
215
216
217
218
# File 'lib/ruby/riddl/utils/notifications_producer.rb', line 209

def response
  backend = @a[0]
  if(backend.subscriptions.include?(@r.last))
    Riddl::Parameter::Complex.new("subscription","text/xml") do
      backend.subscriptions[@r.last].to_s
    end
  else
    @status = 404
  end
end