Interface IApiResponseMapper<TResponse>
- Namespace
- Visus.AddressValidation.Mappers
- Assembly
- Visus.AddressValidation.dll
Abstraction for mapping an API response to an IAddressValidationResponse.
public interface IApiResponseMapper<in TResponse> where TResponse : class
Type Parameters
TResponseThe type of the underlying API response.
Methods
Map(TResponse, IValidationResult?)
Maps response to an instance that implements
IAddressValidationResponse.
IAddressValidationResponse Map(TResponse response, IValidationResult? validationResult = null)
Parameters
responseTResponseThe underlying API response returned by the address validation service.
validationResultIValidationResultCurrent validation state (if any) of the response represented as an instance of IValidationResult.
Returns
- IAddressValidationResponse
An instance that implements IAddressValidationResponse.