Class: UmbrellioUtils::RequestWrapper
- Inherits:
-
Object
- Object
- UmbrellioUtils::RequestWrapper
- Includes:
- Memery
- Defined in:
- lib/umbrellio_utils/request_wrapper.rb
Instance Method Summary collapse
- #[](key) ⇒ Object
- #headers ⇒ Object
-
#initialize(request, remove_xml_attributes: true) ⇒ RequestWrapper
constructor
A new instance of RequestWrapper.
- #ip ⇒ Object
- #rails_params ⇒ Object
- #raw_request ⇒ Object
Constructor Details
#initialize(request, remove_xml_attributes: true) ⇒ RequestWrapper
Returns a new instance of RequestWrapper.
7 8 9 10 |
# File 'lib/umbrellio_utils/request_wrapper.rb', line 7 def initialize(request, remove_xml_attributes: true) self.request = request self.remove_xml_attributes = remove_xml_attributes end |
Instance Method Details
#[](key) ⇒ Object
21 22 23 |
# File 'lib/umbrellio_utils/request_wrapper.rb', line 21 def [](key) params[key] end |
#headers ⇒ Object
45 46 47 |
# File 'lib/umbrellio_utils/request_wrapper.rb', line 45 def headers request.headers end |
#ip ⇒ Object
49 50 51 |
# File 'lib/umbrellio_utils/request_wrapper.rb', line 49 def ip request.ip end |
#rails_params ⇒ Object
25 26 27 |
# File 'lib/umbrellio_utils/request_wrapper.rb', line 25 def rails_params request.params end |
#raw_request ⇒ Object
29 30 31 |
# File 'lib/umbrellio_utils/request_wrapper.rb', line 29 def raw_request request end |