Class: Qeweney::Request

Inherits:
Object
  • Object
show all
Defined in:
lib/syntropy/request_extensions.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#start_stampObject

Returns the value of attribute start_stamp.



7
8
9
# File 'lib/syntropy/request_extensions.rb', line 7

def start_stamp
  @start_stamp
end

Instance Method Details

#respond_with_static_file(path, etag, last_modified, opts) ⇒ Object



9
10
11
12
13
14
15
16
# File 'lib/syntropy/request_extensions.rb', line 9

def respond_with_static_file(path, etag, last_modified, opts)
  cache_headers = (etag || last_modified) ? {
    'etag' => etag,
    'last-modified' => last_modified
  } : {}

  adapter.respond_with_static_file(self, path, opts, cache_headers)
end


22
23
24
# File 'lib/syntropy/request_extensions.rb', line 22

def set_cookie(*)
  adapter.set_cookie(*)
end

#set_response_headers(headers) ⇒ Object



18
19
20
# File 'lib/syntropy/request_extensions.rb', line 18

def set_response_headers(headers)
  adapter.set_response_headers(headers)
end

#upgrade(protocol, custom_headers = nil, &block) ⇒ Object



26
27
28
29
# File 'lib/syntropy/request_extensions.rb', line 26

def upgrade(protocol, custom_headers = nil, &block)
  super(protocol, custom_headers)
  adapter.with_stream(&block)
end