Click or drag to resize
CreateOrderValidator Class
Class representing validator for order finalization.
Inheritance Hierarchy
SystemObject
  CMS.EcommerceCreateOrderValidator

Namespace: CMS.Ecommerce
Assembly: CMS.Ecommerce (in CMS.Ecommerce.dll) Version: 12.0.0
Syntax
C#
public class CreateOrderValidator : IValidator

The CreateOrderValidator type exposes the following members.

Constructors
  NameDescription
Public methodCreateOrderValidator
Initializes a new instance of the CreateOrderValidator class for given cart.
Top
Properties
  NameDescription
Public propertyCart
Gets shopping cart this validator was initialized for.
Public propertyErrors
Gets an enumeration of validation errors associated with this validator. An empty enumeration is returned if validation succeeded.
Public propertyIsValid
Gets a value indicating whether validation succeeded.
Top
Methods
  NameDescription
Public methodValidate
Validates shopping cart before creating order. Validation includes: all required properties must be set, cart must contain at least one item, user must not be disabled, shipping and payment options, cart addresses and user must not be banned if site requires registration.
Protected methodValidateBannedUser
When site requires registration after checkout validates that user is not banned.
Protected methodValidateCartAddresses
Validates shipping and billing addresses match customer and that all cart addresses are valid.
Protected methodValidatePaymentOption
Validates that user is authorized for selected payment option.
Protected methodValidateShippingAndPaymentOptions
Validates applicability of shipping and payment options on their own and with respect to each other.
Protected methodValidateShoppingCart
Validates shopping cart and its items. For more details on what is validated refer to ShoppingCartValidator and ShoppingCartItemValidator.
Top
Extension Methods
  NameDescription
Public Extension MethodContainsTValidatorError
Returns a value indicating whether a validation error of type TValidatorError is in Errors.
(Defined by IValidatorExtensions.)
Public Extension MethodFirstErrorType
Returns Type of the first validation error in Errors.
(Defined by IValidatorExtensions.)
Public Extension MethodGetErrorMessages
Returns collection of localized error messages that occurred during validation.
(Defined by IValidatorExtensions.)
Top
See Also