Class: CPEE::DStore::DoGet
- Inherits:
-
Riddl::Implementation
- Object
- Riddl::Implementation
- CPEE::DStore::DoGet
- Defined in:
- lib/cpee-dstore/implementation.rb
Overview
{{{
Instance Method Summary collapse
Instance Method Details
#response ⇒ Object
28 29 30 31 32 33 34 35 36 37 |
# File 'lib/cpee-dstore/implementation.rb', line 28 def response file = File.join(@a[0],@r[-2],@r[-1]) = file + '.mimetype' if File.exist?(file) && File.exist?() Riddl::Parameter::Complex.new('file',File.read().strip,File.open(file,'rb')) else @status = 404 nil end end |