Package cero

Examples of cero.ConfigurationException


    @Override
    public void setString(String propertyName, String value)
        throws ConfigurationException {
      if (propertyName.equals("name")
          && (value.equals("") || value == null))
        throw new ConfigurationException(
            "Players' name can't be null or empty");
      playerName = value;
      super.setString(propertyName, value);
    }
View Full Code Here


     */
    @Override
    public void setInt(String propertyName, int value)
        throws ConfigurationException {
      if (propertyName.equals("Points limit") && value <= 0)
        throw new ConfigurationException(
            "Points limit must be strictly higher than 0");
      super.setInt(propertyName, value);
    }
View Full Code Here

    @Override
    public void setInt(String propertyName, int value)
        throws ConfigurationException {
      if (propertyName.equals("Cards dealt number") && value <= 0)
        throw new ConfigurationException(
            "The cards dealt number must be strictly higher than 0");
      super.setInt(propertyName, value);
      cardDealtNumber = value;
    }
View Full Code Here

TOP

Related Classes of cero.ConfigurationException

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.