@Override
    public void actionCommit() {

        List errors = new ArrayList();
        try {
            // check if there are any vfs paths entered
            List paths = m_contentCheck.getPaths();
            if (paths.size() == 0) {
                throw new CmsIllegalArgumentException(Messages.get().container(Messages.ERR_NO_VFSPATH_0));
            } else {
                Iterator i = paths.iterator();
                while (i.hasNext()) {
                    String path = (String)i.next();
                    if (!getCms().existsResource(path)) {
                        throw new CmsIllegalArgumentException(Messages.get().container(Messages.ERR_NO_VFSPATH_0));
                    }
                }
            }

            // check if there is at least one test activated
            boolean isActive = false;
            List plugins = m_contentCheck.getPlugins();
            Iterator i = plugins.iterator();
            while (i.hasNext()) {
                I_CmsContentCheck plugin = (I_CmsContentCheck)i.next();
                if (plugin.isActive()) {
                    isActive = true;
                }
            }
            if (!isActive) {
                throw new CmsIllegalArgumentException(Messages.get().container(Messages.ERR_NO_TEST_0));
            }

            // if there was no error, store the content check object in the session and forward it to the
            // check thread
            setDialogObject(m_contentCheck);
            Map params = new HashMap();
            // set the name of this class to get dialog object in report
            params.put(CmsDatabaseExportReport.PARAM_CLASSNAME, this.getClass().getName());
            // set style to display report in correct layout
            params.put(PARAM_STYLE, CmsToolDialog.STYLE_NEW);
            // set close link to get back to overview after finishing the import
            params.put(PARAM_CLOSELINK, getJsp().link(CONTENT_CHECK_RESULT));
            //params.put(PARAM_CLOSELINK, CmsToolManager.linkForToolPath(getJsp(), "/contenttools"));
            getToolManager().jspForwardPage(this, CONTENT_CHECK_REPORT, params);

        } catch (Throwable t) {
            errors.add(t);
        }
        // set the list of errors to display when saving failed
        setCommitErrors(errors);
    }
@ Override public void actionCommit ( ) { List errors = new ArrayList ( ) ; try { List paths = m_contentCheck . getPaths ( ) ; if ( paths . size ( ) == 0 ) { throw new CmsIllegalArgumentException ( Messages . get ( ) . container ( Messages . ERR_NO_VFSPATH_0 ) ) ; } else { Iterator i = paths . iterator ( ) ; while ( i . hasNext ( ) ) { String path = ( String ) i . next ( ) ; if ( ! getCms ( ) . existsResource ( path ) ) { throw new CmsIllegalArgumentException ( Messages . get ( ) . container ( Messages . ERR_NO_VFSPATH_0 ) ) ; } } } boolean isActive = false ; List plugins = m_contentCheck . getPlugins ( ) ; Iterator i = plugins . iterator ( ) ; while ( i . hasNext ( ) ) { I_CmsContentCheck plugin = ( I_CmsContentCheck ) i . next ( ) ; if ( plugin . isActive ( ) ) { isActive = true ; } } if ( ! isActive ) { throw new CmsIllegalArgumentException ( Messages . get ( ) . container ( Messages . ERR_NO_TEST_0 ) ) ; } setDialogObject ( m_contentCheck ) ; Map params = new HashMap ( ) ; params . put ( CmsDatabaseExportReport . PARAM_CLASSNAME , this . getClass ( ) . getName ( ) ) ; params . put ( PARAM_STYLE , CmsToolDialog . STYLE_NEW ) ; params . put ( PARAM_CLOSELINK , getJsp ( ) . link ( CONTENT_CHECK_RESULT ) ) ; getToolManager ( ) . jspForwardPage ( this , CONTENT_CHECK_REPORT , params ) ; } catch ( Throwable t ) { errors . add ( t ) ; } setCommitErrors ( errors ) ; }
@see org.opencms.workplace.CmsWidgetDialog#actionCommit()