Package com.google.gwt.core.ext

Examples of com.google.gwt.core.ext.BadPropertyValueException


        if (cond.isTrue(logger, new DeferredBindingQuery(this,
            activeLinkerNames))) {
          winner = cond;
        }
      } catch (UnableToCompleteException e) {
        BadPropertyValueException t = new BadPropertyValueException(
            prop.getName());
        t.initCause(e);
        throw t;
      }
    }
    assert winner != null : "No active Condition for " + prop.getName();
    return winner;
View Full Code Here


      // Treat as an unknown value.
      //
      String msg = "Error while executing the JavaScript provider for property '"
          + propertyName + "'";
      logger.log(TreeLogger.ERROR, msg, e);
      throw new BadPropertyValueException(propertyName, "<failed to compute>");
    }

    // value may be null if the provider returned an unknown property value.
    if (Arrays.asList(values).contains(value)) {
      return value;
    } else {
      // Bad value due to the provider returning an unknown value.
      // The fact that the provider returned an invalid value will also
      // have been reported to the JS bad property value handler function.
      throw new BadPropertyValueException(propertyName, value);
    }
  }
View Full Code Here

    Property prop = props.find(propertyName);
    if (prop == null) {
      // Don't know this property; that's not good.
      //
      throw new BadPropertyValueException(propertyName);
    }
    return prop;
  }
View Full Code Here

  @Override
  public com.google.gwt.core.ext.ConfigurationProperty getConfigurationProperty(String propertyName)
      throws BadPropertyValueException {
    ConfigurationProperty config = configPropertiesByName.get(propertyName);
    if (config == null) {
      throw new BadPropertyValueException(propertyName);
    }
    return new DefaultConfigurationProperty(config.getName(), config.getValues());
  }
View Full Code Here

        return new DefaultSelectionProperty(value, prop.getFallback(), name,
            possibleValues, prop.getFallbackValuesMap());
      }
    }

    throw new BadPropertyValueException(propertyName);
  }
View Full Code Here

      com.google.gwt.dev.cfg.ConfigurationProperty configurationProperty =
          (com.google.gwt.dev.cfg.ConfigurationProperty) property;
      return new DefaultConfigurationProperty(
          configurationProperty.getName(), configurationProperty.getValues());
    }
    throw new BadPropertyValueException(propertyName);
  }
View Full Code Here

  private BindingProperty getBindingProperty(String propertyName) throws BadPropertyValueException {
    Property property = properties.find(propertyName);
    if (property instanceof BindingProperty) {
      return (BindingProperty) property;
    }
    throw new BadPropertyValueException(propertyName);
  }
View Full Code Here

        if ("product".equals(consoleProfile)) {
            sourceWriter.println("return ProductConfig.Profile.PRODUCT;");
        } else if ("community".equals(consoleProfile)) {
            sourceWriter.println("return ProductConfig.Profile.COMMUNITY;");
        } else {
            throw new BadPropertyValueException(
                    "Invalid value for 'console.profile'. Valid values are 'community' or 'product'!");
        }
        sourceWriter.outdent();
        sourceWriter.println("}");
View Full Code Here

        if (property != null) {
            List<String> values = property.getValues();
            if (values != null && !values.isEmpty()) {
                return values.get(0);
            } else {
                throw new BadPropertyValueException("Missing configuration property '" + name + "'!");
            }
        } else {
            throw new BadPropertyValueException("Missing configuration property '" + name + "'!");
        }
    }
View Full Code Here

TOP

Related Classes of com.google.gwt.core.ext.BadPropertyValueException

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.