Package com.google.gwt.core.ext

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


    SortedSet<JClassType> cssResourceSubtypes = computeOperableTypes(logger);

    if (context.getCachedData(KEY_HAS_CACHED_DATA, Boolean.class) != Boolean.TRUE) {

      ConfigurationProperty prop;
      TreeSet<String> reservedPrefixes = new TreeSet<String>();
      try {
        prop = context.getGeneratorContext().getPropertyOracle()
            .getConfigurationProperty(KEY_RESERVED_PREFIXES);

        // add this configuration property to our requirements
        context.getRequirements().addConfigurationProperty(KEY_RESERVED_PREFIXES);

        for (String value : prop.getValues()) {
          value = value.trim();
          if (value.length() == 0) {
            logger.log(TreeLogger.WARN,
                "Ignoring nonsensical empty string value for "
                    + KEY_RESERVED_PREFIXES + " configuration property");
View Full Code Here


    PropertyOracle propertyOracle = context.getPropertyOracle();

    // See if filename obfuscation should be enabled
    String enableRenaming = null;
    try {
      ConfigurationProperty prop = propertyOracle.getConfigurationProperty(ENABLE_RENAMING);
      getRequirements().addConfigurationProperty(ENABLE_RENAMING);
      enableRenaming = prop.getValues().get(0);
    } catch (BadPropertyValueException e) {
      logger.log(TreeLogger.ERROR, "Bad value for " + ENABLE_RENAMING, e);
      throw new UnableToCompleteException();
    }
View Full Code Here

    }
    logger.log(TreeLogger.TRACE, "Using a shard size of " + shardSize
        + " for TypeSerializerCreator createMethodMap");

    try {
      ConfigurationProperty prop
          = context.getPropertyOracle().getConfigurationProperty(
              GWT_ELIDE_TYPE_NAMES_FROM_RPC);
      elideTypeNames = Boolean.parseBoolean(prop.getValues().get(0));
    } catch (BadPropertyValueException e) {
      logger.log(TreeLogger.ERROR, "The configuration property "
          + GWT_ELIDE_TYPE_NAMES_FROM_RPC
          + " was not defined. Is RemoteService.gwt.xml inherited?");
      throw new UnableToCompleteException();
View Full Code Here

    PropertyOracle propertyOracle = context.getPropertyOracle();

    boolean userAgentRuntimeWarning = true;
    try {
      ConfigurationProperty property =
          propertyOracle.getConfigurationProperty(PROPERTY_USER_AGENT_RUNTIME_WARNING);
      userAgentRuntimeWarning = Boolean.valueOf(property.getValues().get(0));
    } catch (BadPropertyValueException e) {
      logger.log(TreeLogger.WARN, "Unable to find value for '"
          + PROPERTY_USER_AGENT_RUNTIME_WARNING + "'", e);
    }
View Full Code Here

  public static LocaleUtils getInstance(TreeLogger logger,
      PropertyOracle propertyOracle, GeneratorContext context) {
    try {
      SelectionProperty localeProp
          = propertyOracle.getSelectionProperty(logger, PROP_LOCALE);
      ConfigurationProperty runtimeLocaleProp
          = propertyOracle.getConfigurationProperty(PROP_RUNTIME_LOCALES);
      ConfigurationProperty queryParamProp
          = propertyOracle.getConfigurationProperty(PROP_LOCALE_QUERY_PARAM);
      ConfigurationProperty cookieProp
          = propertyOracle.getConfigurationProperty(PROP_LOCALE_COOKIE);
      LocaleInfoContext localeInfoCtx = getLocaleInfoCtx(context);
      LocaleUtils localeUtils = localeInfoCtx.getLocaleUtils(localeProp,
          runtimeLocaleProp, queryParamProp, cookieProp);
      if (localeUtils == null) {
View Full Code Here

   * Look up in the specified property oracle the maximum number of variables to
   * allow per var statement.
   */
  private int getMaxVarsPerStatement(PropertyOracle propertyOracle)
      throws InternalCompilerException, NumberFormatException {
    ConfigurationProperty prop;
    try {
      prop = propertyOracle.getConfigurationProperty(CONFIG_PROP_MAX_VARS);
    } catch (BadPropertyValueException e) {
      throw new InternalCompilerException("Could not find property "
          + CONFIG_PROP_MAX_VARS, e);
    }
    int t = Integer.parseInt(prop.getValues().get(0));
    return t;
  }
View Full Code Here

      logger.log(TreeLogger.TRACE, "Reusing all cached artifacts for " + getProxyQualifiedName());
      return new RebindResult(RebindMode.USE_ALL_CACHED, getProxyQualifiedName());
    }

    try {
      ConfigurationProperty prop =
          context.getPropertyOracle().getConfigurationProperty(
              TypeSerializerCreator.GWT_ELIDE_TYPE_NAMES_FROM_RPC);
      elideTypeNames = Boolean.parseBoolean(prop.getValues().get(0));
    } catch (BadPropertyValueException e) {
      logger.log(TreeLogger.ERROR, "Configuration property "
          + TypeSerializerCreator.GWT_ELIDE_TYPE_NAMES_FROM_RPC
          + " is not defined. Is RemoteService.gwt.xml inherited?");
      throw new UnableToCompleteException();
View Full Code Here

      throws UnableToCompleteException {
    String classPrefix;
    try {
      PropertyOracle propertyOracle =
        context.getGeneratorContext().getPropertyOracle();
      ConfigurationProperty styleProp =
        propertyOracle.getConfigurationProperty(KEY_STYLE);
      obfuscationStyle = CssObfuscationStyle.getObfuscationStyle(
          styleProp.getValues().get(0));

      ConfigurationProperty mergeProp =
        propertyOracle.getConfigurationProperty(KEY_MERGE_ENABLED);
      String merge = mergeProp.getValues().get(0);
      enableMerge = merge.equals("true");

      ConfigurationProperty classPrefixProp =
        propertyOracle.getConfigurationProperty(KEY_OBFUSCATION_PREFIX);
      classPrefix = classPrefixProp.getValues().get(0);

      // add these configuration properties to our requirements
      ClientBundleRequirements requirements = context.getRequirements();
      requirements.addConfigurationProperty(KEY_STYLE);
      requirements.addConfigurationProperty(KEY_MERGE_ENABLED);
View Full Code Here

     * be be worth the effort to simplify this.
     */

    if (context.getCachedData(KEY_HAS_CACHED_DATA, Boolean.class) != Boolean.TRUE) {

      ConfigurationProperty prop;
      TreeSet<String> reservedPrefixes = new TreeSet<String>();
      try {
        prop = context.getGeneratorContext().getPropertyOracle()
            .getConfigurationProperty(KEY_RESERVED_PREFIXES);

        // add this configuration property to our requirements
        context.getRequirements().addConfigurationProperty(KEY_RESERVED_PREFIXES);

        for (String value : prop.getValues()) {
          value = value.trim();
          if (value.length() == 0) {
            logger.log(TreeLogger.WARN,
                "Ignoring nonsensical empty string value for "
                    + KEY_RESERVED_PREFIXES + " configuration property");
View Full Code Here

  }

  private void maybeAddToBlacklist(String propName, Collection<String> blacklist,
      PropertyOracle propOracle) {
    try {
      ConfigurationProperty configProp =
          propOracle.getConfigurationProperty(propName);
      // supports multivalue property
      for (String bannedSymbols : configProp.getValues()) {
        // and comma separated list
        String [] idents = bannedSymbols.split(",");
        for (String ident : idents) {
          String trimmedIdent = ident.trim();
          if (trimmedIdent.length() > 0) {
View Full Code Here

TOP

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

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.