Class: PagSeguro::AuthorizationRequest::RequestSerializer
- Inherits:
-
Object
- Object
- PagSeguro::AuthorizationRequest::RequestSerializer
- Defined in:
- lib/pagseguro/authorization_request/request_serializer.rb
Instance Attribute Summary collapse
-
#request ⇒ Object
Returns the value of attribute request.
Instance Method Summary collapse
- #build_xml ⇒ Object
-
#initialize(request) ⇒ RequestSerializer
constructor
A new instance of RequestSerializer.
Constructor Details
#initialize(request) ⇒ RequestSerializer
Returns a new instance of RequestSerializer.
7 8 9 10 |
# File 'lib/pagseguro/authorization_request/request_serializer.rb', line 7 def initialize(request) @request = request @builder = Nokogiri::XML::Builder end |
Instance Attribute Details
#request ⇒ Object
Returns the value of attribute request.
5 6 7 |
# File 'lib/pagseguro/authorization_request/request_serializer.rb', line 5 def request @request end |
Instance Method Details
#build_xml ⇒ Object
12 13 14 15 16 17 |
# File 'lib/pagseguro/authorization_request/request_serializer.rb', line 12 def build_xml build.to_xml(save_with: Nokogiri::XML::Node::SaveOptions::NO_EMPTY_TAGS | Nokogiri::XML::Node::SaveOptions::FORMAT ) end |