Package org.nbphpcouncil.modules.php.yii.ui.options

Examples of org.nbphpcouncil.modules.php.yii.ui.options.YiiCustomizerPanel


        return errorMessage;
    }

    @NbBundle.Messages("YiiModuleCustomizerExtender.error.source.invalid=Can't find source directory. Project might be broken.")
    private void validate() {
        YiiCustomizerPanel panel = getPanel();
        if (!(panel.isEnabledPlugin())) {
            isValid = true;
            errorMessage = null;
            return;
        }

        // source directory
        FileObject sourceDirectory = phpModule.getSourceDirectory();
        if (sourceDirectory == null) {
            // project may be broken
            isValid = false;
            errorMessage = Bundle.YiiModuleCustomizerExtender_error_source_invalid();
            return;
        }

        // validate
        YiiCustomizerValidator validator = new YiiCustomizerValidator()
                .validateDirectory(sourceDirectory, panel.getSystemPath())
                .validateDirectory(sourceDirectory, panel.getApplicationPath())
                .validateDirectory(sourceDirectory, panel.getZiiPath())
                .validateDirectory(sourceDirectory, panel.getExtPath())
                .validateDirectory(sourceDirectory, panel.getControllersPath())
                .validateDirectory(sourceDirectory, panel.getViewsPath())
                .validateDirectory(sourceDirectory, panel.getThemesPath())
                .validateDirectory(sourceDirectory, panel.getMessagesPath());
        ValidationResult result = validator.getResult();
        if (result.hasWarnings()) {
            isValid = false;
            errorMessage = result.getWarnings().get(0).getMessage();
            return;
View Full Code Here


        return change;
    }

    private YiiCustomizerPanel getPanel() {
        if (component == null) {
            component = new YiiCustomizerPanel();
            component.setEnabledPlugin(isEnabled);
            component.setAutoCreateView(useAutoCreateView);
            component.setFallbackToDefaultViews(isFallbackToDefaultViews);
            component.setSystemPath(systemPath);
            component.setApplicationPath(applicationPath);
View Full Code Here

TOP

Related Classes of org.nbphpcouncil.modules.php.yii.ui.options.YiiCustomizerPanel

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.