Show / Hide Table of Contents

Class ShippingSystem

Inheritance
System.Object
DisposableObject
ApplicationComponent
Service
Service<System.Object>
ServiceWithInstrumentationBase<System.Object>
ShippingSystem
ManualSystem
ShippoSystem
Implements
IApplicationComponent
System.IDisposable
IService
INamed
ILocalizedTimeProvider
IWebClientCaller
IShippingSystemImplementation
IShippingSystem
IConfigurable
IInstrumentable
IExternallyParameterized
Inherited Members
ServiceWithInstrumentationBase<Object>.ExternalParameters
ServiceWithInstrumentationBase<Object>.ExternalParametersForGroups(String[])
ServiceWithInstrumentationBase<Object>.ExternalGetParameter(String, Object, String[])
ServiceWithInstrumentationBase<Object>.ExternalSetParameter(String, Object, String[])
Service<Object>.ComponentDirector
Service.CONFIG_NAME_ATTR
Service.ApplicationDontAutoStartService
Service.Status
Service.Running
Service.Name
Service.TimeLocation
Service.LocalizedTime
Service.Configure(IConfigSectionNode)
Service.Start()
Service.SignalStop()
Service.CheckForCompleteStop()
Service.WaitForCompleteStop()
Service.AcceptManagerVisit(Object, DateTime)
Service.UniversalTimeToLocalizedTime(DateTime)
Service.LocalizedTimeToUniversalTime(DateTime)
Service.AbortStart()
Service.DoSignalStop()
Service.DoCheckForCompleteStop()
Service.CheckServiceInactive()
Service.CheckServiceActive()
Service.CheckServiceActiveOrStarting()
Service.____ObtainPrivateServiceStatusLockObject()
ApplicationComponent.AllComponents
ApplicationComponent.GetAppComponentBySID(UInt64)
ApplicationComponent.GetAppComponentByCommonName(String)
ApplicationComponent.ComponentSID
ApplicationComponent.ComponentStartTime
ApplicationComponent.ComponentCommonName
DisposableObject.DisposeAndNull<T>(T)
DisposableObject.DisposeStarted
DisposableObject.Disposed
DisposableObject.EnsureObjectNotDisposed()
DisposableObject.Dispose()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: NFX.Web.Shipping
Assembly: NFX.Web.dll
Syntax
public abstract class ShippingSystem : ServiceWithInstrumentationBase<object>, IApplicationComponent, IDisposable, IService, INamed, ILocalizedTimeProvider, IWebClientCaller, IShippingSystemImplementation, IShippingSystem, IConfigurable, IInstrumentable, IExternallyParameterized

Constructors

ShippingSystem(String, IConfigSectionNode)

Declaration
public ShippingSystem(string name, IConfigSectionNode node)
Parameters
Type Name Description
System.String name
IConfigSectionNode node

ShippingSystem(String, IConfigSectionNode, Object)

Declaration
public ShippingSystem(string name, IConfigSectionNode node, object director)
Parameters
Type Name Description
System.String name
IConfigSectionNode node
System.Object director

Fields

CONFIG_AUTO_START_ATTR

Declaration
public const string CONFIG_AUTO_START_ATTR = "auto-start"
Field Value
Type Description
System.String

CONFIG_CARRIER_SECTION

Declaration
public const string CONFIG_CARRIER_SECTION = "carrier"
Field Value
Type Description
System.String

CONFIG_CARRIERS_SECTION

Declaration
public const string CONFIG_CARRIERS_SECTION = "carriers"
Field Value
Type Description
System.String

CONFIG_SHIPPING_PROCESSING_SECTION

Declaration
public const string CONFIG_SHIPPING_PROCESSING_SECTION = "shipping-processing"
Field Value
Type Description
System.String

CONFIG_SHIPPING_SYSTEM_HOST_SECTION

Declaration
public const string CONFIG_SHIPPING_SYSTEM_HOST_SECTION = "shipping-system-host"
Field Value
Type Description
System.String

CONFIG_SHIPPING_SYSTEM_SECTION

Declaration
public const string CONFIG_SHIPPING_SYSTEM_SECTION = "shipping-system"
Field Value
Type Description
System.String

DEFAULT_LOG_LEVEL

Declaration
public const MessageType DEFAULT_LOG_LEVEL = MessageType.Warning
Field Value
Type Description
MessageType

DHL_EXPRESS_CARRIER_ID

Declaration
public const string DHL_EXPRESS_CARRIER_ID = "DHL_EXPRESS"
Field Value
Type Description
System.String

FEDEX_CARRIER_ID

Declaration
public const string FEDEX_CARRIER_ID = "FEDEX"
Field Value
Type Description
System.String

UPS_CARRIER_ID

Declaration
public const string UPS_CARRIER_ID = "UPS"
Field Value
Type Description
System.String

USPS_CARRIER_ID

Declaration
public const string USPS_CARRIER_ID = "USPS"
Field Value
Type Description
System.String

Properties

Capabilities

Declaration
public abstract IShippingSystemCapabilities Capabilities { get; }
Property Value
Type Description
IShippingSystemCapabilities

DefaultSessionConnectParams

Declaration
protected ShippingConnectionParameters DefaultSessionConnectParams { get; }
Property Value
Type Description
ShippingConnectionParameters

DefaultSessionConnectParamsCfg

Declaration
[Config("default-session-connect-params")]
public IConfigSectionNode DefaultSessionConnectParamsCfg { get; set; }
Property Value
Type Description
IConfigSectionNode

Instances

Declaration
public static Registry<ShippingSystem> Instances { get; }
Property Value
Type Description
Registry<ShippingSystem>

InstrumentationEnabled

Declaration
[Config(Default = false)]
[ExternalParameter(new string[]{"instrumentation", "shipping"})]
public override bool InstrumentationEnabled { get; set; }
Property Value
Type Description
System.Boolean
Overrides
NFX.ServiceModel.ServiceWithInstrumentationBase<System.Object>.InstrumentationEnabled

IsShippingSystemHost

Declaration
public static bool IsShippingSystemHost { get; }
Property Value
Type Description
System.Boolean

KeepAlive

Declaration
[Config(Default = true)]
public bool KeepAlive { get; set; }
Property Value
Type Description
System.Boolean

LogLevel

Declaration
[Config(Default = MessageType.Warning)]
[ExternalParameter(new string[]{"shipping"})]
public MessageType LogLevel { get; set; }
Property Value
Type Description
MessageType

Pipelined

Declaration
[Config(Default = true)]
public bool Pipelined { get; set; }
Property Value
Type Description
System.Boolean

PreconfiguredShippingCarriers

Declaration
public IRegistry<ShippingCarrier> PreconfiguredShippingCarriers { get; }
Property Value
Type Description
IRegistry<ShippingCarrier>

ShippingSystemHost

Returns process-global shipping system host

Declaration
public static IShippingSystemHost ShippingSystemHost { get; }
Property Value
Type Description
IShippingSystemHost

WebServiceCallTimeoutMs

Declaration
[Config(Default = 20000)]
public int WebServiceCallTimeoutMs { get; set; }
Property Value
Type Description
System.Int32

Methods

___SetShippingSystemHost(IShippingSystemHostImplementation)

Sets process-global shipping system host. If ShippingSystemStarter is used then the host may be auto-injected from configuration if it is there. Developers: Do not call this method as it is used for dependency injection from system code

Declaration
public static void ___SetShippingSystemHost(IShippingSystemHostImplementation host)
Parameters
Type Name Description
IShippingSystemHostImplementation host

AutoStartSystems()

Declaration
public static void AutoStartSystems()

CreateLabel(ShippingSession, IShippingContext, Shipment)

Declaration
public abstract Label CreateLabel(ShippingSession session, IShippingContext context, Shipment shipment)
Parameters
Type Name Description
ShippingSession session
IShippingContext context
Shipment shipment
Returns
Type Description
Label

Destructor()

Declaration
protected override void Destructor()
Overrides
Service.Destructor()

DoAcceptManagerVisit(Object, DateTime)

Declaration
protected override void DoAcceptManagerVisit(object manager, DateTime managerNow)
Parameters
Type Name Description
System.Object manager
System.DateTime managerNow
Overrides
Service.DoAcceptManagerVisit(Object, DateTime)

DoConfigure(IConfigSectionNode)

Declaration
protected override void DoConfigure(IConfigSectionNode node)
Parameters
Type Name Description
IConfigSectionNode node
Overrides
Service.DoConfigure(IConfigSectionNode)

DoStart()

Declaration
protected override void DoStart()
Overrides
Service.DoStart()

DoStartSession(ShippingConnectionParameters)

Declaration
protected abstract ShippingSession DoStartSession(ShippingConnectionParameters cParams = null)
Parameters
Type Name Description
ShippingConnectionParameters cParams
Returns
Type Description
ShippingSession

DoWaitForCompleteStop()

Declaration
protected override void DoWaitForCompleteStop()
Overrides
Service.DoWaitForCompleteStop()

EstimateShippingCost(ShippingSession, IShippingContext, Shipment)

Declaration
public abstract ShippingRate EstimateShippingCost(ShippingSession session, IShippingContext context, Shipment shipment)
Parameters
Type Name Description
ShippingSession session
IShippingContext context
Shipment shipment
Returns
Type Description
ShippingRate

GetShippingCarriers(ShippingSession, IShippingContext)

Declaration
public virtual IEnumerable<ShippingCarrier> GetShippingCarriers(ShippingSession session, IShippingContext context)
Parameters
Type Name Description
ShippingSession session
IShippingContext context
Returns
Type Description
System.Collections.Generic.IEnumerable<ShippingCarrier>

GetTrackingURL(ShippingSession, IShippingContext, String, String)

Declaration
public virtual string GetTrackingURL(ShippingSession session, IShippingContext context, string carrierID, string trackingNumber)
Parameters
Type Name Description
ShippingSession session
IShippingContext context
System.String carrierID
System.String trackingNumber
Returns
Type Description
System.String

Log(MessageType, String, String, Exception, Nullable<Guid>, String)

Declaration
protected Guid Log(MessageType type, string from, string message, Exception error = null, Guid? relatedMessageID = default (Guid? ), string parameters = null)
Parameters
Type Name Description
MessageType type
System.String from
System.String message
System.Exception error
System.Nullable<System.Guid> relatedMessageID
System.String parameters
Returns
Type Description
System.Guid

MakeDefaultSessionConnectParams(IConfigSectionNode)

Declaration
protected abstract ShippingConnectionParameters MakeDefaultSessionConnectParams(IConfigSectionNode paramsSection)
Parameters
Type Name Description
IConfigSectionNode paramsSection
Returns
Type Description
ShippingConnectionParameters

StartSession(ShippingConnectionParameters)

Declaration
public ShippingSession StartSession(ShippingConnectionParameters cParams = null)
Parameters
Type Name Description
ShippingConnectionParameters cParams
Returns
Type Description
ShippingSession

StatCreateLabel()

Declaration
protected void StatCreateLabel()

StatCreateLabelError()

Declaration
protected void StatCreateLabelError()

StatEstimateShippingCostCount()

Declaration
protected void StatEstimateShippingCostCount()

StatEstimateShippingCostErrorCount()

Declaration
protected void StatEstimateShippingCostErrorCount()

StatTrackShipmentCount()

Declaration
protected void StatTrackShipmentCount()

StatTrackShipmentErrorCount()

Declaration
protected void StatTrackShipmentErrorCount()

StatValidateAddressCount()

Declaration
protected void StatValidateAddressCount()

StatValidateAddressErrorCount()

Declaration
protected void StatValidateAddressErrorCount()

TrackShipment(ShippingSession, IShippingContext, String, String)

Declaration
public virtual TrackInfo TrackShipment(ShippingSession session, IShippingContext context, string carrierID, string trackingNumber)
Parameters
Type Name Description
ShippingSession session
IShippingContext context
System.String carrierID
System.String trackingNumber
Returns
Type Description
TrackInfo

ValidateAddress(ShippingSession, IShippingContext, Address, out ValidateShippingAddressException)

Declaration
public abstract Address ValidateAddress(ShippingSession session, IShippingContext context, Address address, out ValidateShippingAddressException error)
Parameters
Type Name Description
ShippingSession session
IShippingContext context
Address address
ValidateShippingAddressException error
Returns
Type Description
Address

Implements

IApplicationComponent
System.IDisposable
IService
INamed
ILocalizedTimeProvider
IWebClientCaller
IShippingSystemImplementation
IShippingSystem
IConfigurable
IInstrumentable
IExternallyParameterized

Extension Methods

MiscUtils.NonNull<T>(T, Func<Exception>, String)
ObjectValueConversion.AsString(Object, String, ConvertErrorHandling)
ObjectValueConversion.AsNonNullOrEmptyString(Object)
ObjectValueConversion.AsLaconicConfig(Object, ConfigSectionNode, String, ConvertErrorHandling)
ObjectValueConversion.AsJSONConfig(Object, ConfigSectionNode, String, ConvertErrorHandling)
ObjectValueConversion.AsXMLConfig(Object, ConfigSectionNode, ConvertErrorHandling)
ObjectValueConversion.AsChar(Object, Char, ConvertErrorHandling)
ObjectValueConversion.AsNullableChar(Object, Nullable<Char>, ConvertErrorHandling)
ObjectValueConversion.AsByte(Object, Byte, ConvertErrorHandling)
ObjectValueConversion.AsNullableByte(Object, Nullable<Byte>, ConvertErrorHandling)
ObjectValueConversion.AsSByte(Object, SByte, ConvertErrorHandling)
ObjectValueConversion.AsNullableSByte(Object, Nullable<SByte>, ConvertErrorHandling)
ObjectValueConversion.AsShort(Object, Int16, ConvertErrorHandling)
ObjectValueConversion.AsNullableShort(Object, Nullable<Int16>, ConvertErrorHandling)
ObjectValueConversion.AsUShort(Object, UInt16, ConvertErrorHandling)
ObjectValueConversion.AsNullableUShort(Object, Nullable<UInt16>, ConvertErrorHandling)
ObjectValueConversion.AsInt(Object, Int32, ConvertErrorHandling)
ObjectValueConversion.AsNullableInt(Object, Nullable<Int32>, ConvertErrorHandling)
ObjectValueConversion.AsUInt(Object, UInt32, ConvertErrorHandling)
ObjectValueConversion.AsNullableUInt(Object, Nullable<UInt32>, ConvertErrorHandling)
ObjectValueConversion.AsLong(Object, Int64, ConvertErrorHandling)
ObjectValueConversion.AsNullableLong(Object, Nullable<Int64>, ConvertErrorHandling)
ObjectValueConversion.AsULong(Object, UInt64, ConvertErrorHandling)
ObjectValueConversion.AsNullableULong(Object, Nullable<UInt64>, ConvertErrorHandling)
ObjectValueConversion.AsDouble(Object, Double, ConvertErrorHandling)
ObjectValueConversion.AsNullableDouble(Object, Nullable<Double>, ConvertErrorHandling)
ObjectValueConversion.AsFloat(Object, Single, ConvertErrorHandling)
ObjectValueConversion.AsNullableFloat(Object, Nullable<Single>, ConvertErrorHandling)
ObjectValueConversion.AsDecimal(Object, Decimal, ConvertErrorHandling)
ObjectValueConversion.AsNullableDecimal(Object, Nullable<Decimal>, ConvertErrorHandling)
ObjectValueConversion.AsBool(Object, Boolean, ConvertErrorHandling)
ObjectValueConversion.AsNullableBool(Object, Nullable<Boolean>, ConvertErrorHandling)
ObjectValueConversion.AsGUID(Object, Guid, ConvertErrorHandling)
ObjectValueConversion.AsNullableGUID(Object, Nullable<Guid>, ConvertErrorHandling)
ObjectValueConversion.AsDateTime(Object)
ObjectValueConversion.AsDateTime(Object, DateTime, ConvertErrorHandling)
ObjectValueConversion.AsNullableDateTime(Object, Nullable<DateTime>, ConvertErrorHandling)
ObjectValueConversion.AsGDID(Object)
ObjectValueConversion.AsGDID(Object, GDID, ConvertErrorHandling)
ObjectValueConversion.AsNullableGDID(Object, Nullable<GDID>, ConvertErrorHandling)
ObjectValueConversion.AsGDIDSymbol(Object)
ObjectValueConversion.AsGDIDSymbol(Object, GDIDSymbol, ConvertErrorHandling)
ObjectValueConversion.AsNullableGDIDSymbol(Object, Nullable<GDIDSymbol>, ConvertErrorHandling)
ObjectValueConversion.AsTimeSpan(Object)
ObjectValueConversion.AsTimeSpan(Object, TimeSpan, ConvertErrorHandling)
ObjectValueConversion.AsNullableTimeSpan(Object, Nullable<TimeSpan>, ConvertErrorHandling)
ObjectValueConversion.AsEnum<TEnum>(Object, TEnum, ConvertErrorHandling)
ObjectValueConversion.AsNullableEnum<TEnum>(Object, Nullable<TEnum>, ConvertErrorHandling)
ObjectValueConversion.AsUri(Object, Uri, ConvertErrorHandling)
JSONExtensions.ToJSON(Object, JSONWritingOptions)
JSONExtensions.ToJSON(Object, TextWriter, JSONWritingOptions)
JSONExtensions.ToJSON(Object, Stream, JSONWritingOptions, Encoding)
ErlObject.ToErlObject(Object)
ErlObject.ToErlObject(Object, ErlTypeOrder, Boolean)
Back to top Copyright © 2006-2018 Agnicore Inc
Generated by DocFX