public PropertiesProcessor getRunnerPropertiesProcessor()

in tc-sbt-runner-server/src/main/java/jetbrains/buildServer/sbt/SbtRunnerRunType.java [27:40]


    public PropertiesProcessor getRunnerPropertiesProcessor() {
        return new PropertiesProcessor() {
            public Collection<InvalidProperty> process(Map<String, String> props) {
                List<InvalidProperty> errors = new ArrayList<InvalidProperty>();
                if (!SbtRunnerConstants.AUTO_INSTALL_FLAG.equalsIgnoreCase(props.get(SbtRunnerConstants.SBT_INSTALLATION_MODE_PARAM)) && StringUtil.isEmptyOrSpaces(props.get(SbtRunnerConstants.SBT_HOME_PARAM))) {
                    errors.add(new InvalidProperty(SbtRunnerConstants.SBT_HOME_PARAM, "SBT home path must be specified"));
                }
                if (SbtRunnerConstants.AUTO_INSTALL_FLAG.equalsIgnoreCase(props.get(SbtRunnerConstants.SBT_INSTALLATION_MODE_PARAM))) {
                    props.remove(SbtRunnerConstants.SBT_HOME_PARAM);
                }
                return errors;
            }
        };
    }