public FoaShippingGatewayMethod(IGatewayResource gatewayResource, IShipMethod shipMethod, IShipCountry shipCountry, IGatewayProviderSettings gatewayProviderSettings) : base(gatewayResource, shipMethod, shipCountry) { _processorSettings = gatewayProviderSettings.ExtendedData.GetProcessorSettings(); _shipMethod = shipMethod; }
/// <summary> /// Saves the processor settings to an extended data collection /// </summary> /// <param name="extendedData">The <see cref="ExtendedDataCollection"/></param> /// <param name="processorSettings">The <see cref="FedExProcessorSettings"/> to be serialized and saved</param> public static void SaveProcessorSettings(this ExtendedDataCollection extendedData, FoaProcessorSettings processorSettings) { var settingsJson = JsonConvert.SerializeObject(processorSettings); extendedData.SetValue(Constants.ExtendedDataKeys.ProcessorSettings, settingsJson); }