001/**
002 *   Copyright (C) 2011-2012 Typesafe Inc. <http://typesafe.com>
003 */
004package com.typesafe.config;
005
006/**
007 * Implement this <em>in addition to</em> {@link ConfigIncluder} if you want to
008 * support inclusion of files with the {@code include classpath("resource")}
009 * syntax. If you do not implement this but do implement {@link ConfigIncluder},
010 * attempts to load classpath resources will use the default includer.
011 */
012public interface ConfigIncluderClasspath {
013    /**
014     * Parses another item to be included. The returned object typically would
015     * not have substitutions resolved. You can throw a ConfigException here to
016     * abort parsing, or return an empty object, but may not return null.
017     *
018     * @param context
019     *            some info about the include context
020     * @param what
021     *            the include statement's argument
022     * @return a non-null ConfigObject
023     */
024    ConfigObject includeResources(ConfigIncludeContext context, String what);
025}