Last active
December 11, 2015 23:48
-
-
Save ayato-p/4679067 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class Constants{ | |
public static final Constants HOGE_CD = new Constants( "1" ); | |
public static final Constants PIYO_CD = new Constants( "2" ); | |
//つらつらと色々な定数が定義されてます… | |
private String value; | |
/** | |
* コンストラクタ | |
*/ | |
private Constants( String pValue ) { | |
this.value = pValue; | |
} | |
/** | |
* 定数値取得 | |
*/ | |
public String getValue() { | |
return value; | |
} | |
/** | |
* 定数値取得 | |
*/ | |
public Integer getIntegerValue() { | |
return Integer.valueOf( value ); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment