Class: RequesterCredentialsHandler

Inherits:
SOAP::Header::SimpleHandler
  • Object
show all
Defined in:
lib/paypal-business/paypal.rb

Overview

Requester CredentialsHander == internal class used to communicate with paypal api

Constant Summary collapse

HeaderName =
XSD::QName.new('urn:ebay:api:PayPalAPI', 'RequesterCredentials')
CredentialsName =
XSD::QName.new('urn:ebay:apis:eBLBaseComponents', 'Credentials')
UsernameName =
XSD::QName.new(nil, 'Username')
PasswordName =
XSD::QName.new(nil, 'Password')
SubjectName =
XSD::QName.new(nil, 'Subject')

Instance Method Summary collapse

Constructor Details

#initialize(username, password, subject) ⇒ RequesterCredentialsHandler

Returns a new instance of RequesterCredentialsHandler.



37
38
39
40
# File 'lib/paypal-business/paypal.rb', line 37

def initialize(username, password, subject)
  super(HeaderName)
  @username, @password, @subject = username, password, subject
end

Instance Method Details

#on_simple_outboundObject



42
43
44
# File 'lib/paypal-business/paypal.rb', line 42

def on_simple_outbound
  {CredentialsName => {UsernameName => @username, PasswordName => @password, SubjectName => @subject}}
end