View Javadoc

1   /*
2    * Copyright 2004-2005 Germinus XXI
3    *
4    * Licensed under the Apache License, Version 2.0 (the "License")
5    * you may not use this file except in compliance with the License.
6    * You may obtain a copy of the License at
7    *
8    *     http://www.apache.org/licenses/LICENSE-2.0
9    *
10   * Unless required by applicable law or agreed to in writing, software
11   * distributed under the License is distributed on an "AS IS" BASIS,
12   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13   * See the License for the specific language governing permissions and
14   * limitations under the License.
15   */
16  package com.germinus.easyconf;
17  
18  
19  /***
20   * Thrown when an XML configuration file contains a variable which either
21   * is not of the form <code>${variableName}</code> or is not
22   * defined in any of the properties files associated with its component
23   *
24   * @author  Jorge Ferrer
25   * @version $Revision: 1.2 $
26   *
27   */
28  public class InvalidPropertyException extends ConfigurationException {
29  
30      public InvalidPropertyException(String componentName, Throwable e) {
31          super(componentName, e);
32      }
33  
34      public String getMessage() {
35          return super.getMessage() + ". A variable is either malformed or " +
36          		"makes a reference to " +
37          		"a property which is not defined for this component in " +
38          		"any of its configuration files.";
39      }
40  }