@Override
  protected void doPrepareManifestSummary(
      PortletDataContext portletDataContext, PortletPreferences portletPreferences)
      throws Exception {

    ActionableDynamicQuery banActionableDynamicQuery =
        _mbBanLocalService.getExportActionableDynamicQuery(portletDataContext);

    banActionableDynamicQuery.performCount();

    ActionableDynamicQuery categoryActionableDynamicQuery =
        _mbCategoryLocalService.getExportActionableDynamicQuery(portletDataContext);

    categoryActionableDynamicQuery.performCount();

    ActionableDynamicQuery messageActionableDynamicQuery =
        getMessageActionableDynamicQuery(portletDataContext);

    messageActionableDynamicQuery.performCount();

    ActionableDynamicQuery threadActionableDynamicQuery =
        _mbThreadLocalService.getExportActionableDynamicQuery(portletDataContext);

    threadActionableDynamicQuery.performCount();

    ActionableDynamicQuery threadFlagActionableDynamicQuery =
        _mbThreadFlagLocalService.getExportActionableDynamicQuery(portletDataContext);

    threadFlagActionableDynamicQuery.performCount();
  }
  @Override
  protected void doPrepareManifestSummary(
      PortletDataContext portletDataContext, PortletPreferences portletPreferences)
      throws Exception {

    ActionableDynamicQuery categoryActionableDynamicQuery =
        getCategoryActionableDynamicQuery(portletDataContext);

    categoryActionableDynamicQuery.performCount();

    ActionableDynamicQuery vocabularyActionableDynamicQuery =
        getVocabularyActionableDynamicQuery(portletDataContext);

    vocabularyActionableDynamicQuery.performCount();
  }
  @Override
  protected void doPrepareManifestSummary(
      PortletDataContext portletDataContext, PortletPreferences portletPreferences)
      throws Exception {

    ActionableDynamicQuery actionableDynamicQuery =
        GadgetLocalServiceUtil.getExportActionableDynamicQuery(portletDataContext);

    actionableDynamicQuery.performCount();
  }
  @Override
  protected void doPrepareManifestSummary(
      PortletDataContext portletDataContext, PortletPreferences portletPreferences)
      throws Exception {

    ActionableDynamicQuery actionableDynamicQuery =
        getRoleActionableDynamicQuery(portletDataContext, false);

    actionableDynamicQuery.performCount();
  }
  @Override
  protected void doPrepareManifestSummary(PortletDataContext portletDataContext) throws Exception {

    ManifestSummary manifestSummary = portletDataContext.getManifestSummary();

    ActionableDynamicQuery layoutPrototypeExportActionableDynamicQuery =
        new LayoutPrototypeExportActionableDynamicQuery(portletDataContext);

    manifestSummary.addModelAdditionCount(
        LayoutPrototype.class, layoutPrototypeExportActionableDynamicQuery.performCount());
  }
  @Override
  protected void doPrepareManifestSummary(
      PortletDataContext portletDataContext, PortletPreferences portletPreferences)
      throws Exception {

    List<DDMTemplate> ddmTemplates = new ArrayList<>();

    ActionableDynamicQuery ddmStructureActionableDynamicQuery =
        getDDMStructureActionableDynamicQuery(portletDataContext, ddmTemplates);

    ddmStructureActionableDynamicQuery.performCount();

    ActionableDynamicQuery recordSetActionableDynamicQuery =
        _ddlRecordSetLocalService.getExportActionableDynamicQuery(portletDataContext);

    recordSetActionableDynamicQuery.performCount();

    ActionableDynamicQuery recordActionableDynamicQuery =
        getRecordActionableDynamicQuery(portletDataContext);

    recordActionableDynamicQuery.performCount();
  }
  protected long getModelDeletionCount() throws PortalException, SystemException {
    ActionableDynamicQuery actionableDynamicQuery =
        new SystemEventActionableDynamicQuery() {
          @Override
          protected void addCriteria(DynamicQuery dynamicQuery) {
            Property classNameIdProperty = PropertyFactoryUtil.forName("classNameId");

            dynamicQuery.add(
                classNameIdProperty.eq(PortalUtil.getClassNameId(AssetVocabulary.class.getName())));

            Property typeProperty = PropertyFactoryUtil.forName("type");

            dynamicQuery.add(typeProperty.eq(SystemEventConstants.TYPE_DELETE));

            _addCreateDateProperty(dynamicQuery);
          }

          @Override
          protected void performAction(Object object) {}

          private void _addCreateDateProperty(DynamicQuery dynamicQuery) {
            if (!_portletDataContext.hasDateRange()) {
              return;
            }

            Property createDateProperty = PropertyFactoryUtil.forName("createDate");

            Date startDate = _portletDataContext.getStartDate();

            dynamicQuery.add(createDateProperty.ge(startDate));

            Date endDate = _portletDataContext.getEndDate();

            dynamicQuery.add(createDateProperty.le(endDate));
          }
        };

    actionableDynamicQuery.setGroupId(_portletDataContext.getScopeGroupId());

    return actionableDynamicQuery.performCount();
  }