Package fedex :: Package services :: Module address_validation_service :: Class FedexAddressValidationRequest
[hide private]
[frames] | no frames]

Class FedexAddressValidationRequest

source code

                   object --+    
                            |    
base_service.FedexBaseService --+
                                |
                               FedexAddressValidationRequest

This class allows you validate anywhere from one to a hundred addresses in one go. Create AddressToValidate WSDL objects and add them to each instance of this request using add_address().

Instance Methods [hide private]
 
__init__(self, config_obj, *args, **kwargs)
This constructor should only be called by children of the class.
source code
 
_prepare_wsdl_objects(self)
Create the data structure and get it ready for the WSDL request.
source code
 
_assemble_and_send_request(self)
Fires off the Fedex request.
source code
 
add_address(self, address_item)
Adds an address to self.AddressesToValidate.
source code

Inherited from base_service.FedexBaseService: create_wsdl_object_of_type, send_request

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Instance Variables [hide private]
  AddressesToValidate
Holds the AddressToValidate WSDL object.

Inherited from base_service.FedexBaseService: ClientDetail, TransactionDetail, VersionId, WebAuthenticationDetail, config_obj, logger, response

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, config_obj, *args, **kwargs)
(Constructor)

source code 

This constructor should only be called by children of the class. As is such, only the optional keyword arguments caught by **kwargs will be documented.

Parameters:
  • config_obj (FedexConfig) - A valid FedexConfig object.
Overrides: object.__init__

_prepare_wsdl_objects(self)

source code 

Create the data structure and get it ready for the WSDL request.

Overrides: base_service.FedexBaseService._prepare_wsdl_objects

_assemble_and_send_request(self)

source code 

Fires off the Fedex request.

Overrides: base_service.FedexBaseService._assemble_and_send_request

Warning: NEVER CALL THIS METHOD DIRECTLY. CALL send_request(), WHICH RESIDES ON FedexBaseService AND IS INHERITED.

add_address(self, address_item)

source code 

Adds an address to self.AddressesToValidate.

Parameters:
  • address_item (WSDL object, type of AddressToValidate WSDL object.) - A AddressToValidate, created by calling create_wsdl_object_of_type('AddressToValidate') on this FedexAddressValidationRequest object. See examples/create_shipment.py for more details.