Try our conversational search powered by Generative AI!

Class DefaultOrderFactory

Responsible for creating implementations of order interfaces

Inheritance
System.Object
DefaultOrderFactory
Implements
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: EPiServer.Commerce.Order
Assembly: EPiServer.Business.Commerce.dll
Version: 10.8.0
Syntax
[Obsolete("The IOrderFactory interface is no longer used. Use IOrderGroupFactory instead. Will remain at least until January 2018.")]
public class DefaultOrderFactory : IOrderFactory

Constructors

DefaultOrderFactory(IOrderRepository)

Initializes a new instance of the DefaultOrderFactory class.

Declaration
public DefaultOrderFactory(IOrderRepository orderRepository)
Parameters
Type Name Description
IOrderRepository orderRepository

The order repository.

Methods

CreateCardPayment()

Creates the card payment.

Declaration
public virtual ICreditCardPayment CreateCardPayment()
Returns
Type Description
ICreditCardPayment

An ICreditCardPayment

CreateCart(Guid, String)

Creates the cart.

Declaration
[Obsolete("This method has been obsoleted. Use 'IOrderRepository.Create<ICart>' instead. Will remain at least until January 2018.")]
public virtual ICart CreateCart(Guid customerId, string name)
Parameters
Type Name Description
System.Guid customerId

The customer guid

System.String name

The name of the order. The name is not unique for each order, instead it's suppose to differentiate orders of the same type.

Returns
Type Description
ICart

An ICart

CreateLineItem(String)

Creates the line item.

Declaration
public virtual ILineItem CreateLineItem(string code)
Parameters
Type Name Description
System.String code

The line item code.

Returns
Type Description
ILineItem

An ILineItem

CreateOrderAddress()

Creates the order address.

Declaration
public virtual IOrderAddress CreateOrderAddress()
Returns
Type Description
IOrderAddress

An IOrderAddress

CreateOrderForm()

Creates the order form.

Declaration
public virtual IOrderForm CreateOrderForm()
Returns
Type Description
IOrderForm

An IOrderForm

CreateOrderNote()

Creates the order note.

Declaration
public virtual IOrderNote CreateOrderNote()
Returns
Type Description
IOrderNote

An IOrderNote

CreatePayment()

Creates the payment.

Declaration
public virtual IPayment CreatePayment()
Returns
Type Description
IPayment

An IPayment

CreatePaymentPlan(Guid, String)

Creates the payment plan.

Declaration
[Obsolete("This method has been obsoleted. Use 'IOrderRepository.Create<IPaymentPlan>' instead. Will remain at least until January 2018.")]
public virtual IPaymentPlan CreatePaymentPlan(Guid customerId, string name)
Parameters
Type Name Description
System.Guid customerId

The customer guid

System.String name

The name of the order. The name is not unique for each order, instead it's suppose to differentiate orders of the same type.

Returns
Type Description
IPaymentPlan

An IPaymentPlan

CreatePurchaseOrder(Guid)

Creates the purchase order.

Declaration
[Obsolete("This method has been obsoleted. Use 'IOrderRepository.Create<IPurchaseOrder>' instead. Will remain at least until January 2018.")]
public virtual IPurchaseOrder CreatePurchaseOrder(Guid customerId)
Parameters
Type Name Description
System.Guid customerId

The customer guid

Returns
Type Description
IPurchaseOrder

An IPurchaseOrder

CreateShipment()

Creates the shipment.

Declaration
public virtual IShipment CreateShipment()
Returns
Type Description
IShipment

An IShipment

CreateTaxValue()

Creates the tax value.

Declaration
public virtual ITaxValue CreateTaxValue()
Returns
Type Description
ITaxValue

An ITaxValue

Implements