KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > gcc > properties > PropertyLog


1 /*
2  * Copyright 2004 The Apache Software Foundation or its licensors, as
3  * applicable.
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
14  * implied.
15  *
16  * See the License for the specific language governing permissions and
17  * limitations under the License.
18  */

19 package gcc.properties;
20
21 public class PropertyLog
22 {
23     public static PropertyLog getInstance(String instanceName)
24     {
25         PropertyLog log = new PropertyLog();
26         log.init(instanceName);
27         return log;
28     }
29
30     private String _instanceName;
31
32     public String getInstanceName()
33     {
34         return _instanceName;
35     }
36
37     protected void init(String instanceName)
38     {
39         _instanceName = instanceName;
40     }
41
42     public void debugUsingValue(String value)
43     {
44         System.out.println( "PropertyLog.debugUsingValue(): NEEDS IMPLEMENTATION??" );
45     }
46
47     public void debugUsingDefaultValue(String defaultValue)
48     {
49         System.out.println( "PropertyLog.debugUsingValue(): NEEDS IMPLEMENTATION??" );
50     }
51
52     public String errorMissingValueForRequiredProperty(String property, String context)
53     {
54         String msg = "PropertyLog.errorMissingValueForRequiredProperty(): property: " + property + ", context: " + context;
55         System.out.println( msg );
56         return msg;
57     }
58
59     public String errorMissingValueForRequiredSystemProperty(String property, String refProperty, String context)
60     {
61         String msg = "PropertyLog.errorMissingValueForRequiredSystemProperty(): property: " + property + ", refProperty: " + refProperty + ", context: " + context;
62         System.out.println( msg );
63         return msg;
64     }
65 }
66
Popular Tags