01: /*
02: * All content copyright (c) 2003-2006 Terracotta, Inc., except as may otherwise be noted in a separate copyright notice. All rights reserved.
03: */
04: package com.tc.config.schema.setup;
05:
06: import com.tc.config.schema.repository.ApplicationsRepository;
07: import com.tc.config.schema.repository.MutableBeanRepository;
08:
09: import java.io.File;
10:
11: /**
12: * An object that knows how to create configuration from some source and put it into repositories.
13: */
14: public interface ConfigurationCreator {
15:
16: /**
17: * Load up the configuration into the various repositories.
18: */
19: void createConfigurationIntoRepositories(
20: MutableBeanRepository l1BeanRepository,
21: MutableBeanRepository l2sBeanRepository,
22: MutableBeanRepository systemBeanRepository,
23: ApplicationsRepository applicationsRepository)
24: throws ConfigurationSetupException;
25:
26: /**
27: * @return the directory containing the configuration file from which config was loaded,
28: * <em>IF<em> such a thing exists; this may well return <code>null</code> (for
29: * example, if configuration was loaded from a URL rather than a file).
30: */
31: File directoryConfigurationLoadedFrom();
32:
33: /**
34: * @return true if the ConfigurationSource was a trusted one.
35: * Non-trusted sources require that the server be queried to enforce
36: * that the configuration-mode is development.
37: */
38: boolean loadedFromTrustedSource();
39:
40: String describeSources();
41:
42: }
|