Examples of withFallback()


Examples of com.crashnote.external.config.ConfigObject.withFallback()

        final ConfigObject obj = includeURLWithoutFallback(context, url);

        // now use the fallback includer if any and merge
        // its result.
        if (fallback != null && fallback instanceof ConfigIncluderURL) {
            return obj.withFallback(((ConfigIncluderURL) fallback).includeURL(context, url));
        } else {
            return obj;
        }
    }
View Full Code Here

Examples of com.crashnote.external.config.ConfigObject.withFallback()

        final ConfigObject obj = includeFileWithoutFallback(context, file);

        // now use the fallback includer if any and merge
        // its result.
        if (fallback != null && fallback instanceof ConfigIncluderFile) {
            return obj.withFallback(((ConfigIncluderFile) fallback).includeFile(context, file));
        } else {
            return obj;
        }
    }
View Full Code Here

Examples of com.crashnote.external.config.ConfigObject.withFallback()

        final ConfigObject obj = includeResourceWithoutFallback(context, resource);

        // now use the fallback includer if any and merge
        // its result.
        if (fallback != null && fallback instanceof ConfigIncluderClasspath) {
            return obj.withFallback(((ConfigIncluderClasspath) fallback).includeResources(context,
                    resource));
        } else {
            return obj;
        }
    }
View Full Code Here

Examples of com.typesafe.config.Config.withFallback()

         * We are merging, because the Configuration object already contains some information the web-interface needs.
         *
         */
        }
        return new Configuration(
                config.withFallback(configuration.getWrappedConfiguration().underlying())
        );
    }

    private void setupLocalUser(ApiClient api, SimpleAccountRealm realm, Application app) {
        final Configuration config = app.configuration();
View Full Code Here

Examples of com.typesafe.config.Config.withFallback()

            // User configuration will not be loaded in test mode
            String workspace = getWorkspace();
            File userConfFile = new File(workspace, DEFAULT_USER_CONFIG_FILENAME);
            if (userConfFile.exists()) {
                Config userConf = ConfigFactory.parseFile(userConfFile);
                conf = userConf.withFallback(conf);
            }
        }

        conf = conf.resolve();
        return new ConfigParser().parseAndCheck("greed", conf.getConfig("greed"), GreedConfig.class);
View Full Code Here

Examples of com.typesafe.config.Config.withFallback()

      final String configId = entry.getKey();
      final Config configField = fieldBundle.getConfig(configId);

      final FormField formField = fieldEntry(configId,
          configField.withFallback(fieldDefault));

      fieldList.add(formField);

    }
View Full Code Here

Examples of com.typesafe.config.Config.withFallback()

        try {
            T objectShell = type.newInstance();
            String className = type.getName();
            Config objectConfig = configObject.toConfig();
            try {
                objectConfig = objectConfig.withFallback(globalConfig.getConfig(className));
            } catch (ConfigException logged) {
                log.debug("failed to get defaults for {}", className, logged);
            }
            populateObjectFields(info, objectShell, objectConfig);
            return objectShell;
View Full Code Here

Examples of com.typesafe.config.Config.withFallback()

      final String configId = entry.getKey();
      final Config configField = fieldBundle.getConfig(configId);

      final FormField formField = fieldEntry(configId,
          configField.withFallback(fieldDefault));

      fieldList.add(formField);

    }
View Full Code Here

Examples of com.typesafe.config.Config.withFallback()

        try {
            T objectShell = type.newInstance();
            String className = type.getName();
            Config objectConfig = configObject.toConfig();
            try {
                objectConfig = objectConfig.withFallback(globalConfig.getConfig(className));
            } catch (ConfigException logged) {
                log.debug("failed to get defaults for {}", className, logged);
            }
            populateObjectFields(info, objectShell, objectConfig);
            return objectShell;
View Full Code Here

Examples of com.typesafe.config.Config.withFallback()

      final String configId = entry.getKey();
      final Config configField = fieldBundle.getConfig(configId);

      final FormField formField = fieldEntry(configId,
          configField.withFallback(fieldDefault));

      fieldList.add(formField);

    }
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.