Package net.sf.eclipsecs.core.util

Examples of net.sf.eclipsecs.core.util.CheckstylePluginException


        final URL ruleset = cfgTranslator.getRuleset();
        // build or get the checkconfig
        final ICheckConfiguration checkCfg =
                this.createOrGetCheckstyleConfig(pcWorkingCopy, ruleset, cfgTranslator.getExecutionId());
        if (checkCfg == null) {
            throw new CheckstylePluginException(
                    String.format("Failed to construct CheckConfig,SKIPPING checkstyle configuration"));
        }
        // update filesets (include and exclude patterns)
        cfgTranslator.updateCheckConfigWithIncludeExcludePatterns(pcWorkingCopy, checkCfg);
        /**
 
View Full Code Here


                if (configName.equals(copy.getName())) {
                    if (this.remoteConfigurationType.equals(copy.getType())) {
                        workingCopy = copy;
                        break;
                    }
                    throw new CheckstylePluginException(String.format(
                            "A local Checkstyle configuration allready exists with name "
                                    + " [%s] with incompatible type [%s]",
                            configName, copy.getType()));
                }
            }
View Full Code Here

    public URL getRuleset() throws CheckstylePluginException, CoreException {
        final URL ruleset =
                this.resourceResolver.resolveLocation(this.getConfigLocation());
        if (ruleset == null) {
            throw new CheckstylePluginException(
                    String.format("Failed to resolve RuleSet from configLocation,SKIPPING Eclipse checkstyle configuration"));
        }
        return ruleset;
    }
View Full Code Here

    private void copyOut(URL src, File dest) throws CheckstylePluginException {
        try {
            FileUtils.copyURLToFile(src, dest);
        } catch (IOException e) {
            throw new CheckstylePluginException("Failed to copy file "
                    + src.getFile()
                    + ", SKIPPING Eclipse checkstyle configuration");
        }
    }
View Full Code Here

        Properties properties = new Properties();
        if (propertiesLocation != null) {
            final URL url =
                    this.resourceResolver.resolveLocation(propertiesLocation);
            if (url == null) {
                throw new CheckstylePluginException(String.format(
                        "Failed to resolve propertiesLocation [%s]",
                        propertiesLocation));
            }
            try {
                properties.load(url.openStream());
            } catch (IOException e) {
                throw new CheckstylePluginException(
                        String.format(
                                "Failed to LOAD properties from propertiesLocation [%s]",
                                propertiesLocation));
            }
        }
View Full Code Here

                // beware of windows path separator
                final String escapedPropertyExpansion =
                        StringEscapeUtils.escapeJava(propertyExpansion);
                props.load(new StringReader(escapedPropertyExpansion));
            } catch (IOException e) {
                throw new CheckstylePluginException(String.format(
                        "[%s]: Failed to checkstyle propertyExpansion [%s]",
                        CheckstyleEclipseConstants.LOG_PREFIX,
                        propertyExpansion));
            }
        }
View Full Code Here

TOP

Related Classes of net.sf.eclipsecs.core.util.CheckstylePluginException

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.