OSDN Git Service

著作権表示を変更しました。
[filelock/repo.git] / filelock / src / main / java / jp / gr / java_conf / u6k / filelock / AppInfo.java
1 /*\r
2  * Copyright (C) 2007 u6k.yu1@gmail.com, All Rights Reserved.\r
3  *\r
4  * Redistribution and use in source and binary forms, with or without\r
5  * modification, are permitted provided that the following conditions\r
6  * are met:\r
7  *\r
8  *    1. Redistributions of source code must retain the above copyright\r
9  *       notice, this list of conditions and the following disclaimer.\r
10  *\r
11  *    2. Redistributions in binary form must reproduce the above copyright\r
12  *       notice, this list of conditions and the following disclaimer in the\r
13  *       documentation and/or other materials provided with the distribution.\r
14  *\r
15  *    3. Neither the name of Clarkware Consulting, Inc. nor the names of its\r
16  *       contributors may be used to endorse or promote products derived\r
17  *       from this software without prior written permission. For written\r
18  *       permission, please contact clarkware@clarkware.com.\r
19  *\r
20  * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,\r
21  * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND\r
22  * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL\r
23  * CLARKWARE CONSULTING OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,\r
24  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\r
25  * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,\r
26  * OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF\r
27  * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING\r
28  * NEGLIGENCE OR OTHERWISE) ARISING IN  ANY WAY OUT OF THE USE OF THIS SOFTWARE,\r
29  * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
30  */\r
31 \r
32 package jp.gr.java_conf.u6k.filelock;\r
33 \r
34 import java.util.ResourceBundle;\r
35 \r
36 /**\r
37  * <p>\r
38  * アプリケーションの情報を保持します。\r
39  * </p>\r
40  * \r
41  * @author $Author$\r
42  * @version $Rev$ $Date$\r
43  */\r
44 public final class AppInfo {\r
45 \r
46     /**\r
47      * <p>\r
48      * アプリケーションの題名。\r
49      * </p>\r
50      */\r
51     private String title;\r
52 \r
53     /**\r
54      * <p>\r
55      * アプリケーションのバージョン。\r
56      * </p>\r
57      */\r
58     private String version;\r
59 \r
60     /**\r
61      * <p>\r
62      * アプリケーションの著作権情報。\r
63      * </p>\r
64      */\r
65     private String copyright;\r
66 \r
67     /**\r
68      * <p>\r
69      * 「filelock.properties」からアプリケーションの情報を読み込み、{@link AppInfo}クラスを初期化します。\r
70      * </p>\r
71      */\r
72     public AppInfo() {\r
73         ResourceBundle rb = ResourceBundle.getBundle("filelock");\r
74         this.title = rb.getString("app.title");\r
75         this.version = rb.getString("app.version");\r
76         this.copyright = rb.getString("app.copyright");\r
77     }\r
78 \r
79     /**\r
80      * <p>\r
81      * アプリケーションの題名を返します。\r
82      * </p>\r
83      * \r
84      * @return アプリケーションの題名。\r
85      */\r
86     public String getTitle() {\r
87         return this.title;\r
88     }\r
89 \r
90     /**\r
91      * <p>\r
92      * アプリケーションのバージョンを返します。\r
93      * </p>\r
94      * \r
95      * @return アプリケーションのバージョン。\r
96      */\r
97     public String getVersion() {\r
98         return this.version;\r
99     }\r
100 \r
101     /**\r
102      * <p>\r
103      * アプリケーションの著作権情報を返します。\r
104      * </p>\r
105      * \r
106      * @return アプリケーションの著作権情報。\r
107      */\r
108     public String getCopyright() {\r
109         return this.copyright;\r
110     }\r
111 \r
112 }\r