Package net.sourceforge.cruisecontrol

Examples of net.sourceforge.cruisecontrol.CruiseControlException


  }
  public Hashtable getProperties() {
    return properties;
  }
  public void validate() throws CruiseControlException {
    if (stream == null) { throw new CruiseControlException("'stream' is a required attribute for Accurev"); }
  }
View Full Code Here


        // Load the persisted session information from file
        Properties sessionProperties = null;
        try {
            sessionProperties = Util.loadPropertiesFromFile(sessionFile);
        } catch (IOException e) {
            throw new CruiseControlException (e);
        }

        // Look up and return the full session ID
        return sessionProperties.getProperty(sessionName);
    }
View Full Code Here

  }
  /**
   * Selects a format for hist as in (-f)
   */
  public void setFormatExpanded(char format) throws CruiseControlException {
    if ("evstx".indexOf(format) < 0) { throw new CruiseControlException(
        "Invalid format specifier (use one of 'e' 'v' 's' 't' 'x') " + format); }
    addOption("-f", new String(new char[]{format}));
  }
View Full Code Here

        if (verbose) {
          LOG.info(line);
        }
      }
    } catch (IOException ex) {
      throw new CruiseControlException("Error reading input");
    }
    return !badSyntax;
  }
View Full Code Here

   *
   * @throws CruiseControlException
   *           if the command was not executed successfully
   */
  public void assertSuccess() throws CruiseControlException {
    if (!isSuccess()) { throw new CruiseControlException("Error running " + toString()); }
  }
View Full Code Here

        Commandline commandline = new Commandline();
        String execCommand;
        try {
            execCommand = (ssDir != null) ? new File(ssDir, "ss.exe").getCanonicalPath() : "ss.exe";
        } catch (IOException e) {
            throw new CruiseControlException(e);
        }

        commandline.setExecutable(execCommand);
        commandline.createArgument().setValue("history");
        commandline.createArgument().setValue(vssPath);
View Full Code Here

         *
         * @throws CruiseControlException if the validation fails
         */
        public void validate() throws CruiseControlException {
            if (sourceControls.isEmpty()) {
                throw new CruiseControlException("Error: there must be at least one source control in a "
                        + getEntryName() + " block.");
            }
            if (parent == null) {
                throw new CruiseControlException("Error: " + getEntryName()
                        + " blocks must be contained within compound blocks.");
            }
        }
View Full Code Here

        return properties;
    }

    public void validate() throws CruiseControlException {
        if (mksroot == null) {
            throw new CruiseControlException("'mksroot' is a required attribute on MKS");
        }
    }
View Full Code Here

     *
     *  @throws CruiseControlException if there was a configuration error.
     */
    public void validate() throws CruiseControlException {
        if (getMailHost() == null) {
            throw new CruiseControlException("'mailhost' not specified in configuration file.");
        }
        if (getReturnAddress() == null) {
            throw new CruiseControlException("'returnaddress' not specified in configuration file.");
        }
        if (getUsername() != null && getPassword() == null) {
            throw new CruiseControlException("'password' is required if 'username' is set for email.");
        }
        if (getPassword() != null && getUsername() == null) {
            throw new CruiseControlException("'username' is required if 'password' is set for email.");
        }
    }
View Full Code Here

        try {
            cl = Class.forName(getEmailAddressMapper());
            mapper = (EmailAddressMapper) cl.newInstance();
        } catch (InstantiationException ie) {
            LOG.fatal("Could not instantiate class", ie);
            throw new CruiseControlException("Could not instantiate class: "
                + getEmailAddressMapper());
        } catch (ClassNotFoundException cnfe) {
            LOG.fatal("Could not find class", cnfe);
            throw new CruiseControlException("Could not find class: "
                + getEmailAddressMapper());
        } catch (IllegalAccessException iae) {
            LOG.fatal("Illegal Access", iae);
            throw new CruiseControlException("Illegal Access class: "
                + getEmailAddressMapper());
        }

        mapper.open(this);
View Full Code Here

TOP

Related Classes of net.sourceforge.cruisecontrol.CruiseControlException

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.