001 /* 002 * Licensed to the Apache Software Foundation (ASF) under one or more 003 * contributor license agreements. See the NOTICE file distributed with 004 * this work for additional information regarding copyright ownership. 005 * The ASF licenses this file to You under the Apache License, Version 2.0 006 * (the "License"); you may not use this file except in compliance with 007 * the License. You may obtain a copy of the License at 008 * 009 * http://www.apache.org/licenses/LICENSE-2.0 010 * 011 * Unless required by applicable law or agreed to in writing, software 012 * distributed under the License is distributed on an "AS IS" BASIS, 013 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 014 * See the License for the specific language governing permissions and 015 * limitations under the License. 016 */ 017 018 package org.apache.commons.configuration; 019 020 /** 021 * <p> 022 * Definition of an interface for objects that can create a configuration. 023 * </p> 024 * <p> 025 * This interface defines an abstract way of creating a 026 * {@code Configuration} object. It does not assume any specific way of 027 * how this is done; this is completely in the responsibility of an 028 * implementation class. There is just a single method that returns the 029 * configuration constructed by this builder. 030 * </p> 031 * 032 * @author <a href="http://commons.apache.org/configuration/team-list.html">Commons Configuration team</a> 033 * @version $Id: ConfigurationBuilder.java 1208781 2011-11-30 21:11:02Z oheger $ 034 */ 035 public interface ConfigurationBuilder 036 { 037 /** 038 * Returns the configuration provided by this builder. An implementation has 039 * to perform all necessary steps for creating and initializing a 040 * {@code Configuration} object. 041 * 042 * @return the configuration 043 * @throws ConfigurationException if an error occurs 044 */ 045 Configuration getConfiguration() throws ConfigurationException; 046 }