Class TravelMandatoryAttributesValidator

java.lang.Object
de.hybris.platform.servicelayer.interceptor.impl.LocalizedMessageAwareValidator
de.hybris.platform.servicelayer.interceptor.impl.MandatoryAttributesValidator
de.hybris.platform.ndc182shoppingservices.interceptor.impl.TravelMandatoryAttributesValidator
All Implemented Interfaces:
de.hybris.platform.servicelayer.interceptor.Interceptor, de.hybris.platform.servicelayer.interceptor.ValidateInterceptor

public class TravelMandatoryAttributesValidator extends de.hybris.platform.servicelayer.interceptor.impl.MandatoryAttributesValidator
The ndc 18.2 extension of MandatoryAttributesValidator
  • Nested Class Summary

    Nested classes/interfaces inherited from class de.hybris.platform.servicelayer.interceptor.impl.MandatoryAttributesValidator

    de.hybris.platform.servicelayer.interceptor.impl.MandatoryAttributesValidator.MissingMandatoryAttributesException
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected boolean
    Checks if the object is instance of ConsignmentModel and if the consignment belongs to an order with SalesApplication equal to NDC.
    void
    onValidate(Object model, de.hybris.platform.servicelayer.interceptor.InterceptorContext ctx)
    This method overrides the parent one, since an order placed from ndc could not be payed in advance, hence the consignment won't have the shipping address.

    Methods inherited from class de.hybris.platform.servicelayer.interceptor.impl.MandatoryAttributesValidator

    setModelService, setTypeService

    Methods inherited from class de.hybris.platform.servicelayer.interceptor.impl.LocalizedMessageAwareValidator

    getLocalizedMessage, setL10nService

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • TravelMandatoryAttributesValidator

      public TravelMandatoryAttributesValidator()
  • Method Details

    • onValidate

      public void onValidate(Object model, de.hybris.platform.servicelayer.interceptor.InterceptorContext ctx) throws de.hybris.platform.servicelayer.interceptor.InterceptorException
      This method overrides the parent one, since an order placed from ndc could not be payed in advance, hence the consignment won't have the shipping address.
      Specified by:
      onValidate in interface de.hybris.platform.servicelayer.interceptor.ValidateInterceptor
      Overrides:
      onValidate in class de.hybris.platform.servicelayer.interceptor.impl.MandatoryAttributesValidator
      Parameters:
      model - the model
      ctx - the context
      Throws:
      de.hybris.platform.servicelayer.interceptor.InterceptorException
    • isNdcConsigmentModel

      protected boolean isNdcConsigmentModel(Object model)
      Checks if the object is instance of ConsignmentModel and if the consignment belongs to an order with SalesApplication equal to NDC.
      Parameters:
      model - the model
      Returns:
      true if the model is a ndc consignmentModel.