Examples of MissingFieldException


Examples of civquest.parser.ruleset.exception.MissingFieldException

  }

  private boolean getInfoOn(Section section) throws RulesetException {
    Field infoOnField = section.getField("infoOn");
    if (infoOnField == null) {
      throw new MissingFieldException(section, "infoOn",
                      "Happened in Messages.getInfoOn");
    } else if (!infoOnField.isBoolValue()) {
      throw new InvalidFieldValueException(infoOnField, "Bool",
                         "Happ1ened in Messages.getInfoOn");
    } else {
View Full Code Here

Examples of civquest.parser.ruleset.exception.MissingFieldException

  // interprets errorDests-field.
  private void setErrorDests(Section settingsSection, Map dests) throws RulesetException {
    Field errorField = settingsSection.getField("errorDests");

    if (errorField == null) {
      throw new MissingFieldException(settingsSection, "errorDests",
                      "Happened within Messages.setErrorDests");
    } else {
      errDests = new Destination[errorField.getNumberOfValues()];
      for (int n = 0; n < errorField.getNumberOfValues(); n++) {
        if (!errorField.isStringValue(n)) {
View Full Code Here

Examples of civquest.parser.ruleset.exception.MissingFieldException

    public Field getField(String name, String commentIfFail)
    throws RulesetException {
   
    if (!fields.containsKey(name)) {
      throw new MissingFieldException(this, name, commentIfFail);
    } else {
      return fields.get(name);
    }
  }
View Full Code Here

Examples of com.thoughtworks.xstream.converters.reflection.MissingFieldException

    @Deprecated
    public BeanProperty property(final Class<?> cls, final String name) {
        BeanProperty beanProperty = null;
        final PropertyDescriptor descriptor = buildMap(cls).get(name);
        if (descriptor == null) {
            throw new MissingFieldException(cls.getName(), name);
        }
        if (descriptor.getReadMethod() != null && descriptor.getWriteMethod() != null) {
            beanProperty = new BeanProperty(cls, descriptor.getName(), descriptor.getPropertyType());
        }
        return beanProperty;
View Full Code Here

Examples of com.thoughtworks.xstream.converters.reflection.MissingFieldException

     * @param name
     */
    public PropertyDescriptor propertyDescriptor(final Class<?> type, final String name) {
        final PropertyDescriptor descriptor = buildMap(type).get(name);
        if (descriptor == null) {
            throw new MissingFieldException(type.getName(), name);
        }
        return descriptor;
    }
View Full Code Here

Examples of com.thoughtworks.xstream.converters.reflection.MissingFieldException

                    final Class<?> type = determineType(reader, result, propertyName);
                    final Object value = context.convertAnother(result, type);
                    beanProvider.writeProperty(result, propertyName, value);
                    seenProperties.add(new FastField(resultType, propertyName));
                } else {
                    throw new MissingFieldException(resultType.getName(), propertyName);
                }
            }
            reader.moveUp();
        }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.