@Override
  public void onRecordChange(final IMRPSourceEvent event) {
    final Object model = event.getModel();

    if (event.isChange() && InterfaceWrapperHelper.isInstanceOf(model, I_DD_Order.class)) {
      // Do nothing if the DD Order was just created because there is nothing we can do
      if (event.isNew()) {
        return;
      }

      final I_DD_Order ddOrder = InterfaceWrapperHelper.create(model, I_DD_Order.class);

      //
      // Create/update MRP records
      createUpdateMRPRecords(ddOrder);
    } else if (event.isChange()
        && InterfaceWrapperHelper.isInstanceOf(model, I_DD_OrderLine.class)) {
      final I_DD_OrderLine ddOrderLine = InterfaceWrapperHelper.create(model, I_DD_OrderLine.class);
      createUpdateMRPRecords(ddOrderLine);
    } else if (event.isChange()
        && InterfaceWrapperHelper.isInstanceOf(model, I_DD_OrderLine_Alternative.class)) {
      final I_DD_OrderLine_Alternative ddOrderLineAlt =
          InterfaceWrapperHelper.create(model, I_DD_OrderLine_Alternative.class);
      createUpdateMRPRecords(ddOrderLineAlt);
    }
  }
  @Override
  protected void onRecordDeleted(final IMRPSourceEvent event) {
    super.onRecordDeleted(event);

    //
    // Delete MRP alternatives, if any
    final Object model = event.getModel();
    if (InterfaceWrapperHelper.isInstanceOf(model, I_DD_OrderLine_Alternative.class)) {
      final I_DD_OrderLine_Alternative ddOrderLineAlt =
          InterfaceWrapperHelper.create(model, I_DD_OrderLine_Alternative.class);
      deleteMRPAlternatives(ddOrderLineAlt);
    }
  }