{"id":654,"date":"2022-09-10T18:40:53","date_gmt":"2023-09-11T18:17:59","guid":{"rendered":"https:\/\/www.silicloud.com\/ja\/blog\/index.php\/2023\/11\/30\/java%e3%81%ae%e3%83%aa%e3%83%95%e3%83%ac%e3%82%af%e3%82%b7%e3%83%a7%e3%83%b3%e3%81%ae%e4%be%8b%e3%81%ae%e3%83%81%e3%83%a5%e3%83%bc%e3%83%88%e3%83%aa%e3%82%a2%e3%83%ab\/"},"modified":"2025-08-01T01:24:33","modified_gmt":"2025-07-31T16:24:33","slug":"java%e3%81%ae%e3%83%aa%e3%83%95%e3%83%ac%e3%82%af%e3%82%b7%e3%83%a7%e3%83%b3%e3%81%ae%e4%be%8b%e3%81%ae%e3%83%81%e3%83%a5%e3%83%bc%e3%83%88%e3%83%aa%e3%82%a2%e3%83%ab","status":"publish","type":"post","link":"https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%ae%e3%83%aa%e3%83%95%e3%83%ac%e3%82%af%e3%82%b7%e3%83%a7%e3%83%b3%e3%81%ae%e4%be%8b%e3%81%ae%e3%83%81%e3%83%a5%e3%83%bc%e3%83%88%e3%83%aa%e3%82%a2%e3%83%ab\/","title":{"rendered":"Java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306e\u4f8b\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb"},"content":{"rendered":"<p>Java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306f\u3001\u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u306e\u5b9f\u884c\u6642\u306e\u632f\u308b\u821e\u3044\u3092\u691c\u67fb\u304a\u3088\u3073\u5909\u66f4\u3059\u308b\u6a5f\u80fd\u3092\u63d0\u4f9b\u3057\u307e\u3059\u3002Java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306f\u3001\u30b3\u30a2Java\u306e\u9ad8\u5ea6\u306a\u30c8\u30d4\u30c3\u30af\u306e1\u3064\u3067\u3059\u3002Java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u3092\u4f7f\u7528\u3059\u308b\u3068\u3001\u30b3\u30f3\u30d1\u30a4\u30eb\u6642\u306b\u30a2\u30af\u30bb\u30b9\u3067\u304d\u306a\u3044\u30af\u30e9\u30b9\u3001\u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30fc\u30b9\u3001\u5217\u6319\u578b\u3092\u5b9f\u884c\u6642\u306b\u691c\u67fb\u3057\u3001\u305d\u306e\u69cb\u9020\u3001\u30e1\u30bd\u30c3\u30c9\u3001\u30d5\u30a3\u30fc\u30eb\u30c9\u60c5\u5831\u3092\u53d6\u5f97\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u3092\u4f7f\u7528\u3057\u3066\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u3092\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u5316\u3057\u3001\u30e1\u30bd\u30c3\u30c9\u3092\u547c\u3073\u51fa\u3057\u3001\u30d5\u30a3\u30fc\u30eb\u30c9\u306e\u5024\u3092\u5909\u66f4\u3059\u308b\u3053\u3068\u3082\u3067\u304d\u307e\u3059\u3002<\/p>\n<h2>Java\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3<\/h2>\n<ol>\n<li style=\"list-style-type: none;\">\n<ol>Java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3<\/ol>\n<\/li>\n<\/ol>\n<p>&nbsp;<\/p>\n<ol>\n<li style=\"list-style-type: none;\">\n<ol>\u30af\u30e9\u30b9\u306e\u305f\u3081\u306eJava\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3<\/ol>\n<\/li>\n<\/ol>\n<p>\u30af\u30e9\u30b9\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u3092\u53d6\u5f97\u3059\u308b<br \/>\n\u30b9\u30fc\u30d1\u30fc\u30af\u30e9\u30b9\u3092\u53d6\u5f97\u3059\u308b<br \/>\n\u516c\u958b\u3055\u308c\u3066\u3044\u308b\u30e1\u30f3\u30d0\u30fc\u30af\u30e9\u30b9\u3092\u53d6\u5f97\u3059\u308b<br \/>\n\u5ba3\u8a00\u3055\u308c\u305f\u30af\u30e9\u30b9\u3092\u53d6\u5f97\u3059\u308b<br \/>\n\u5ba3\u8a00\u30af\u30e9\u30b9\u3092\u53d6\u5f97\u3059\u308b<br \/>\n\u30d1\u30c3\u30b1\u30fc\u30b8\u540d\u3092\u53d6\u5f97\u3059\u308b<br \/>\n\u30af\u30e9\u30b9\u306e\u4fee\u98fe\u5b50\u3092\u53d6\u5f97\u3059\u308b<br \/>\n\u30bf\u30a4\u30d7\u30d1\u30e9\u30e1\u30fc\u30bf\u3092\u53d6\u5f97\u3059\u308b<br \/>\n\u5b9f\u88c5\u3055\u308c\u305f\u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30fc\u30b9\u3092\u53d6\u5f97\u3059\u308b<br \/>\n\u3059\u3079\u3066\u306e\u516c\u958b\u3055\u308c\u3066\u3044\u308b\u30e1\u30bd\u30c3\u30c9\u3092\u53d6\u5f97\u3059\u308b<br \/>\n\u3059\u3079\u3066\u306e\u516c\u958b\u3055\u308c\u3066\u3044\u308b\u30b3\u30f3\u30b9\u30c8\u30e9\u30af\u30bf\u3092\u53d6\u5f97\u3059\u308b<br \/>\n\u3059\u3079\u3066\u306e\u516c\u958b\u3055\u308c\u3066\u3044\u308b\u30d5\u30a3\u30fc\u30eb\u30c9\u3092\u53d6\u5f97\u3059\u308b<br \/>\n\u3059\u3079\u3066\u306e\u6ce8\u91c8\u3092\u53d6\u5f97\u3059\u308b<\/p>\n<p>\u30d5\u30a3\u30fc\u30eb\u30c9\u306e\u305f\u3081\u306eJava\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3<\/p>\n<p>\u516c\u958b\u3055\u308c\u3066\u3044\u308b\u30d5\u30a3\u30fc\u30eb\u30c9\u3092\u53d6\u5f97\u3059\u308b<br \/>\n\u30d5\u30a3\u30fc\u30eb\u30c9\u306e\u5ba3\u8a00\u30af\u30e9\u30b9<br \/>\n\u30d5\u30a3\u30fc\u30eb\u30c9\u306e\u578b\u3092\u53d6\u5f97\u3059\u308b<br \/>\n\u516c\u958b\u3055\u308c\u3066\u3044\u308b\u30d5\u30a3\u30fc\u30eb\u30c9\u306e\u5024\u3092\u53d6\u5f97\/\u8a2d\u5b9a\u3059\u308b<br \/>\n\u30d7\u30e9\u30a4\u30d9\u30fc\u30c8\u30d5\u30a3\u30fc\u30eb\u30c9\u306e\u5024\u3092\u53d6\u5f97\/\u8a2d\u5b9a\u3059\u308b<\/p>\n<p>\u30e1\u30bd\u30c3\u30c9\u306e\u305f\u3081\u306eJava\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3<\/p>\n<p>\u516c\u958b\u3055\u308c\u3066\u3044\u308b\u30e1\u30bd\u30c3\u30c9\u3092\u53d6\u5f97\u3059\u308b<br \/>\n\u516c\u958b\u3055\u308c\u3066\u3044\u308b\u30e1\u30bd\u30c3\u30c9\u3092\u5b9f\u884c\u3059\u308b<br \/>\n\u30d7\u30e9\u30a4\u30d9\u30fc\u30c8\u30e1\u30bd\u30c3\u30c9\u3092\u5b9f\u884c\u3059\u308b<\/p>\n<p>\u30b3\u30f3\u30b9\u30c8\u30e9\u30af\u30bf\u306e\u305f\u3081\u306eJava\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3<\/p>\n<p>\u516c\u958b\u3055\u308c\u3066\u3044\u308b\u30b3\u30f3\u30b9\u30c8\u30e9\u30af\u30bf\u3092\u53d6\u5f97\u3059\u308b<br \/>\n\u30b3\u30f3\u30b9\u30c8\u30e9\u30af\u30bf\u3092\u4f7f\u7528\u3057\u3066\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u3092\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u5316\u3059\u308b<\/p>\n<p>\u6ce8\u91c8\u306e\u305f\u3081\u306eJava\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3<\/p>\n<ol>Java\u306b\u304a\u3051\u308b\u53cd\u6620<\/ol>\n<p>Java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306f\u975e\u5e38\u306b\u5f37\u529b\u306a\u6982\u5ff5\u3067\u3042\u308a\u3001\u901a\u5e38\u306e\u30d7\u30ed\u30b0\u30e9\u30df\u30f3\u30b0\u3067\u306f\u307b\u3068\u3093\u3069\u5f79\u306b\u7acb\u305f\u306a\u3044\u304c\u3001Java\u3084J2EE\u306e\u591a\u304f\u306e\u30d5\u30ec\u30fc\u30e0\u30ef\u30fc\u30af\u306e\u57fa\u790e\u3068\u306a\u3063\u3066\u3044\u307e\u3059\u3002Java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u3092\u4f7f\u7528\u3059\u308b\u3044\u304f\u3064\u304b\u306e\u30d5\u30ec\u30fc\u30e0\u30ef\u30fc\u30af\u306f\u3001\u4ee5\u4e0b\u306e\u901a\u308a\u3067\u3059\u3002<\/p>\n<ol>\n<li style=\"list-style-type: none;\">\n<ol>JUnit &#8211; @Test\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u3092\u89e3\u6790\u3057\u3066\u30c6\u30b9\u30c8\u30e1\u30bd\u30c3\u30c9\u3092\u53d6\u5f97\u3057\u3001\u305d\u308c\u3092\u5b9f\u884c\u3059\u308b\u305f\u3081\u306b\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u3092\u4f7f\u7528\u3057\u307e\u3059\u3002<\/ol>\n<\/li>\n<\/ol>\n<p>&nbsp;<\/p>\n<ol>\n<li style=\"list-style-type: none;\">\n<ol>Spring &#8211; \u4f9d\u5b58\u6027\u6ce8\u5165\u3001\u8a73\u7d30\u306fSpring\u306e\u4f9d\u5b58\u6027\u6ce8\u5165\u3092\u53c2\u7167\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/ol>\n<\/li>\n<\/ol>\n<p>&nbsp;<\/p>\n<ol>\n<li style=\"list-style-type: none;\">\n<ol>Tomcat\u30a6\u30a7\u30d6\u30b3\u30f3\u30c6\u30ca\u30fc &#8211; web.xml\u30d5\u30a1\u30a4\u30eb\u3068\u30ea\u30af\u30a8\u30b9\u30c8URI\u3092\u89e3\u6790\u3057\u3066\u3001\u8981\u6c42\u3092\u6b63\u3057\u3044\u30e2\u30b8\u30e5\u30fc\u30eb\u306b\u8ee2\u9001\u3057\u307e\u3059\u3002<\/ol>\n<\/li>\n<\/ol>\n<p>&nbsp;<\/p>\n<ol>\n<li style=\"list-style-type: none;\">\n<ol>Eclipse &#8211; \u30e1\u30bd\u30c3\u30c9\u540d\u306e\u81ea\u52d5\u88dc\u5b8c\u6a5f\u80fd<\/ol>\n<\/li>\n<\/ol>\n<p>&nbsp;<\/p>\n<ol>\n<li style=\"list-style-type: none;\">\n<ol>Struts<\/ol>\n<\/li>\n<\/ol>\n<p>&nbsp;<\/p>\n<ol>Hibernate<\/ol>\n<p>\u30ea\u30b9\u30c8\u306f\u7121\u9650\u3067\u3042\u308a\u3001\u3053\u308c\u3089\u306e\u3059\u3079\u3066\u306e\u30d5\u30ec\u30fc\u30e0\u30ef\u30fc\u30af\u306f\u30e6\u30fc\u30b6\u30fc\u5b9a\u7fa9\u306e\u30af\u30e9\u30b9\u3001\u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30fc\u30b9\u3001\u30e1\u30bd\u30c3\u30c9\u306a\u3069\u306e\u77e5\u8b58\u3068\u30a2\u30af\u30bb\u30b9\u3092\u6301\u3063\u3066\u3044\u306a\u3044\u305f\u3081\u3001\u3059\u3079\u3066Java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u3092\u4f7f\u7528\u3057\u3066\u3044\u307e\u3059\u3002\u30af\u30e9\u30b9\u3084\u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30fc\u30b9\u3078\u306e\u30a2\u30af\u30bb\u30b9\u304c\u65e2\u306b\u3042\u308b\u5834\u5408\u306b\u306f\u3001\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306f\u901a\u5e38\u306e\u30d7\u30ed\u30b0\u30e9\u30df\u30f3\u30b0\u3067\u4f7f\u7528\u3057\u306a\u3044\u3079\u304d\u3067\u3059\u3002\u306a\u305c\u306a\u3089\u3001\u4ee5\u4e0b\u306e\u6b20\u70b9\u304c\u3042\u308b\u304b\u3089\u3067\u3059\u3002<\/p>\n<ul class=\"post-ul\">\n<li>Poor Performance &#8211; Since java reflection resolve the types dynamically, it involves processing like scanning the classpath to find the class to load, causing slow performance.<\/li>\n<li>Security Restrictions &#8211; Reflection requires runtime permissions that might not be available for system running under security manager. This can cause you application to fail at runtime because of security manager.<\/li>\n<li>Security Issues &#8211; Using reflection we can access part of code that we are not supposed to access, for example we can access private fields of a class and change it\u2019s value. This can be a serious security threat and cause your application to behave abnormally.<\/li>\n<li>High Maintenance &#8211; Reflection code is hard to understand and debug, also any issues with the code can\u2019t be found at compile time because the classes might not be available, making it less flexible and hard to maintain.<\/li>\n<\/ul>\n<ol>\u30af\u30e9\u30b9\u306e\u305f\u3081\u306eJava\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3<\/ol>\n<p>Java\u3067\u306f\u3001\u3059\u3079\u3066\u306e\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306f\u30d7\u30ea\u30df\u30c6\u30a3\u30d6\u578b\u307e\u305f\u306f\u53c2\u7167\u578b\u306e\u3044\u305a\u308c\u304b\u3067\u3059\u3002\u3059\u3079\u3066\u306e\u30af\u30e9\u30b9\u3001enum\u3001\u914d\u5217\u306f\u53c2\u7167\u578b\u3067\u3042\u308a\u3001java.lang.Object\u304b\u3089\u7d99\u627f\u3057\u3066\u3044\u307e\u3059\u3002\u30d7\u30ea\u30df\u30c6\u30a3\u30d6\u578b\u306b\u306f\u3001boolean\u3001byte\u3001short\u3001int\u3001long\u3001char\u3001float\u3001\u304a\u3088\u3073double\u304c\u3042\u308a\u307e\u3059\u3002java.lang.Class\u306f\u3001\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u64cd\u4f5c\u306e\u30a8\u30f3\u30c8\u30ea\u30fc\u30dd\u30a4\u30f3\u30c8\u3067\u3059\u3002\u3059\u3079\u3066\u306e\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306e\u7a2e\u985e\u3054\u3068\u306b\u3001JVM\u306fjava.lang.Class\u306e\u4e0d\u5909\u306a\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u5316\u3057\u3001\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306e\u30e9\u30f3\u30bf\u30a4\u30e0\u30d7\u30ed\u30d1\u30c6\u30a3\u3092\u8abf\u67fb\u3057\u305f\u308a\u3001\u65b0\u3057\u3044\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u3092\u4f5c\u6210\u3057\u305f\u308a\u3001\u30e1\u30bd\u30c3\u30c9\u3092\u547c\u3073\u51fa\u3057\u305f\u308a\u3001\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306e\u30d5\u30a3\u30fc\u30eb\u30c9\u3092\u53d6\u5f97\/\u8a2d\u5b9a\u3059\u308b\u30e1\u30bd\u30c3\u30c9\u3092\u63d0\u4f9b\u3057\u307e\u3059\u3002\u3053\u306e\u30bb\u30af\u30b7\u30e7\u30f3\u3067\u306f\u3001Class\u306e\u91cd\u8981\u306a\u30e1\u30bd\u30c3\u30c9\u306b\u3064\u3044\u3066\u8aac\u660e\u3057\u307e\u3059\u3002\u4fbf\u5b9c\u306e\u305f\u3081\u3001\u7d99\u627f\u968e\u5c64\u3092\u6301\u3064\u3044\u304f\u3064\u304b\u306e\u30af\u30e9\u30b9\u3068\u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30fc\u30b9\u3092\u4f5c\u6210\u3057\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code>package com.scdev.reflection;\r\n\r\npublic interface BaseInterface {\r\n\t\r\n\tpublic int interfaceInt=0;\r\n\t\r\n\tvoid method1();\r\n\t\r\n\tint method2(String str);\r\n}\r\n<\/code><\/pre>\n<pre class=\"post-pre\"><code>package com.scdev.reflection;\r\n\r\npublic class BaseClass {\r\n\r\n\tpublic int baseInt;\r\n\t\r\n\tprivate static void method3(){\r\n\t\tSystem.out.println(\"Method3\");\r\n\t}\r\n\t\r\n\tpublic int method4(){\r\n\t\tSystem.out.println(\"Method4\");\r\n\t\treturn 0;\r\n\t}\r\n\t\r\n\tpublic static int method5(){\r\n\t\tSystem.out.println(\"Method5\");\r\n\t\treturn 0;\r\n\t}\r\n\t\r\n\tvoid method6(){\r\n\t\tSystem.out.println(\"Method6\");\r\n\t}\r\n\t\r\n\t\/\/ inner public class\r\n\tpublic class BaseClassInnerClass{}\r\n\t\t\r\n\t\/\/member public enum\r\n\tpublic enum BaseClassMemberEnum{}\r\n}\r\n<\/code><\/pre>\n<pre class=\"post-pre\"><code>package com.scdev.reflection;\r\n\r\n@Deprecated\r\npublic class ConcreteClass extends BaseClass implements BaseInterface {\r\n\r\n\tpublic int publicInt;\r\n\tprivate String privateString=\"private string\";\r\n\tprotected boolean protectedBoolean;\r\n\tObject defaultObject;\r\n\t\r\n\tpublic ConcreteClass(int i){\r\n\t\tthis.publicInt=i;\r\n\t}\r\n\r\n\t@Override\r\n\tpublic void method1() {\r\n\t\tSystem.out.println(\"Method1 impl.\");\r\n\t}\r\n\r\n\t@Override\r\n\tpublic int method2(String str) {\r\n\t\tSystem.out.println(\"Method2 impl.\");\r\n\t\treturn 0;\r\n\t}\r\n\t\r\n\t@Override\r\n\tpublic int method4(){\r\n\t\tSystem.out.println(\"Method4 overriden.\");\r\n\t\treturn 0;\r\n\t}\r\n\t\r\n\tpublic int method5(int i){\r\n\t\tSystem.out.println(\"Method4 overriden.\");\r\n\t\treturn 0;\r\n\t}\r\n\t\r\n\t\/\/ inner classes\r\n\tpublic class ConcreteClassPublicClass{}\r\n\tprivate class ConcreteClassPrivateClass{}\r\n\tprotected class ConcreteClassProtectedClass{}\r\n\tclass ConcreteClassDefaultClass{}\r\n\t\r\n\t\/\/member enum\r\n\tenum ConcreteClassDefaultEnum{}\r\n\tpublic enum ConcreteClassPublicEnum{}\r\n\t\r\n\t\/\/member interface\r\n\tpublic interface ConcreteClassPublicInterface{}\r\n\r\n}\r\n<\/code><\/pre>\n<p>\u30af\u30e9\u30b9\u306e\u91cd\u8981\u306a\u53cd\u5c04\u30e1\u30bd\u30c3\u30c9\u3092\u3044\u304f\u3064\u304b\u898b\u3066\u307f\u307e\u3057\u3087\u3046\u3002<\/p>\n<h3>\u30af\u30e9\u30b9\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u3092\u53d6\u5f97\u3059\u308b\u3002<\/h3>\n<p>\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306e\u30af\u30e9\u30b9\u3092\u53d6\u5f97\u3059\u308b\u306b\u306f3\u3064\u306e\u65b9\u6cd5\u304c\u3042\u308a\u307e\u3059\u30021\u3064\u76ee\u306f\u3001\u9759\u7684\u5909\u6570class\u3092\u4f7f\u7528\u3059\u308b\u65b9\u6cd5\u3067\u3059\u30022\u3064\u76ee\u306f\u3001\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306egetClass()\u30e1\u30bd\u30c3\u30c9\u3092\u4f7f\u7528\u3059\u308b\u65b9\u6cd5\u3067\u3059\u3002\u307e\u305f\u3001java.lang.Class.forName(String fullyClassifiedClassName)\u3092\u4f7f\u7528\u3059\u308b\u65b9\u6cd5\u3082\u3042\u308a\u307e\u3059\u3002\u30d7\u30ea\u30df\u30c6\u30a3\u30d6\u578b\u3084\u914d\u5217\u306e\u5834\u5408\u3001\u9759\u7684\u5909\u6570class\u3092\u4f7f\u7528\u3059\u308b\u3053\u3068\u3082\u3067\u304d\u307e\u3059\u3002\u30e9\u30c3\u30d1\u30fc\u30af\u30e9\u30b9\u3067\u306f\u3001\u30af\u30e9\u30b9\u3092\u53d6\u5f97\u3059\u308b\u305f\u3081\u306b\u3055\u3089\u306b\u9759\u7684\u5909\u6570TYPE\u304c\u63d0\u4f9b\u3055\u308c\u3066\u3044\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code>\/\/ Get Class using reflection\r\nClass&lt;?&gt; concreteClass = ConcreteClass.class;\r\nconcreteClass = new ConcreteClass(5).getClass();\r\ntry {\r\n\t\/\/ below method is used most of the times in frameworks like JUnit\r\n\t\/\/Spring dependency injection, Tomcat web container\r\n\t\/\/Eclipse auto completion of method names, hibernate, Struts2 etc.\r\n\t\/\/because ConcreteClass is not available at compile time\r\n\tconcreteClass = Class.forName(\"com.scdev.reflection.ConcreteClass\");\r\n} catch (ClassNotFoundException e) {\r\n\te.printStackTrace();\r\n}\r\nSystem.out.println(concreteClass.getCanonicalName()); \/\/ prints com.scdev.reflection.ConcreteClass\r\n\r\n\/\/for primitive types, wrapper classes and arrays\r\nClass&lt;?&gt; booleanClass = boolean.class;\r\nSystem.out.println(booleanClass.getCanonicalName()); \/\/ prints boolean\r\n\r\nClass&lt;?&gt; cDouble = Double.TYPE;\r\nSystem.out.println(cDouble.getCanonicalName()); \/\/ prints double\r\n\r\nClass&lt;?&gt; cDoubleArray = Class.forName(\"[D\");\r\nSystem.out.println(cDoubleArray.getCanonicalName()); \/\/prints double[]\r\n\r\nClass&lt;?&gt; twoDStringArray = String[][].class;\r\nSystem.out.println(twoDStringArray.getCanonicalName()); \/\/ prints java.lang.String[][]\r\n<\/code><\/pre>\n<p>getCanonicalName()\u306f\u3001\u57fa\u5e95\u30af\u30e9\u30b9\u306e\u6b63\u898f\u306a\u540d\u524d\u3092\u8fd4\u3057\u307e\u3059\u3002 java.lang.Class\u306f\u30b8\u30a7\u30cd\u30ea\u30af\u30b9\u3092\u4f7f\u7528\u3057\u3066\u304a\u308a\u3001Class\u306e\u53d6\u5f97\u304c\u30d5\u30ec\u30fc\u30e0\u30ef\u30fc\u30af\u306e\u30d9\u30fc\u30b9\u30af\u30e9\u30b9\u306e\u30b5\u30d6\u30af\u30e9\u30b9\u3067\u3042\u308b\u3053\u3068\u3092\u78ba\u8a8d\u3059\u308b\u306e\u306b\u5f79\u7acb\u3061\u307e\u3059\u3002\u30b8\u30a7\u30cd\u30ea\u30af\u30b9\u3068\u30ef\u30a4\u30eb\u30c9\u30ab\u30fc\u30c9\u306b\u3064\u3044\u3066\u306f\u3001Java Generics Tutorial\u3092\u53c2\u7167\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<h3>\u30b9\u30fc\u30d1\u30fc\u30af\u30e9\u30b9\u3092\u53d6\u5f97\u3059\u308b\u3002<\/h3>\n<p>Class\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306egetSuperclass()\u30e1\u30bd\u30c3\u30c9\u306f\u3001\u30af\u30e9\u30b9\u306e\u30b9\u30fc\u30d1\u30fc\u30af\u30e9\u30b9\u3092\u8fd4\u3057\u307e\u3059\u3002\u3053\u306eClass\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u304cObject\u30af\u30e9\u30b9\u3001\u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30fc\u30b9\u3001\u30d7\u30ea\u30df\u30c6\u30a3\u30d6\u578b\u3001\u307e\u305f\u306fvoid\u3092\u8868\u3059\u5834\u5408\u3001null\u304c\u8fd4\u3055\u308c\u307e\u3059\u3002\u3053\u306e\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u304c\u914d\u5217\u30af\u30e9\u30b9\u3092\u8868\u3059\u5834\u5408\u3001Object\u30af\u30e9\u30b9\u3092\u8868\u3059Class\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u304c\u8fd4\u3055\u308c\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code>Class&lt;?&gt; superClass = Class.forName(\"com.scdev.reflection.ConcreteClass\").getSuperclass();\r\nSystem.out.println(superClass); \/\/ prints \"class com.scdev.reflection.BaseClass\"\r\nSystem.out.println(Object.class.getSuperclass()); \/\/ prints \"null\"\r\nSystem.out.println(String[][].class.getSuperclass());\/\/ prints \"class java.lang.Object\"\r\n<\/code><\/pre>\n<h3>\u30d1\u30d6\u30ea\u30c3\u30af\u30e1\u30f3\u30d0\u30fc\u30af\u30e9\u30b9\u3092\u53d6\u5f97\u3059\u308b<\/h3>\n<p>getClasses()\u30e1\u30bd\u30c3\u30c9\u306f\u3001\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306e\u30af\u30e9\u30b9\u8868\u73fe\u306e\u30af\u30e9\u30b9\u304b\u3089\u3001\u305d\u306e\u30af\u30e9\u30b9\u306b\u542b\u307e\u308c\u308b\u3059\u3079\u3066\u306e\u30d1\u30d6\u30ea\u30c3\u30af\u306a\u30af\u30e9\u30b9\u3001\u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30fc\u30b9\u3001\u304a\u3088\u3073\u5217\u6319\u578b\u3092\u8868\u3059Class\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u3092\u542b\u3080\u914d\u5217\u3092\u8fd4\u3057\u307e\u3059\u3002\u3053\u308c\u306b\u306f\u3001\u30b9\u30fc\u30d1\u30fc\u30af\u30e9\u30b9\u304b\u3089\u7d99\u627f\u3055\u308c\u305f\u30d1\u30d6\u30ea\u30c3\u30af\u30af\u30e9\u30b9\u304a\u3088\u3073\u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30fc\u30b9\u306e\u30e1\u30f3\u30d0\u30fc\u3001\u304a\u3088\u3073\u30af\u30e9\u30b9\u306b\u3088\u3063\u3066\u5ba3\u8a00\u3055\u308c\u305f\u30d1\u30d6\u30ea\u30c3\u30af\u30af\u30e9\u30b9\u304a\u3088\u3073\u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30fc\u30b9\u306e\u30e1\u30f3\u30d0\u30fc\u304c\u542b\u307e\u308c\u307e\u3059\u3002\u3053\u306e\u30e1\u30bd\u30c3\u30c9\u306f\u3001\u3053\u306eClass\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u304c\u30d1\u30d6\u30ea\u30c3\u30af\u306a\u30e1\u30f3\u30d0\u30fc\u30af\u30e9\u30b9\u3084\u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30fc\u30b9\u3092\u6301\u3063\u3066\u3044\u306a\u3044\u5834\u5408\u3001\u307e\u305f\u306f\u3053\u306eClass\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u304c\u30d7\u30ea\u30df\u30c6\u30a3\u30d6\u578b\u3001\u914d\u5217\u30af\u30e9\u30b9\u3001\u307e\u305f\u306fvoid\u3092\u8868\u3057\u3066\u3044\u308b\u5834\u5408\u306b\u306f\u3001\u9577\u30550\u306e\u914d\u5217\u3092\u8fd4\u3057\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code>Class&lt;?&gt;[] classes = concreteClass.getClasses();\r\n\/\/[class com.scdev.reflection.ConcreteClass$ConcreteClassPublicClass, \r\n\/\/class com.scdev.reflection.ConcreteClass$ConcreteClassPublicEnum, \r\n\/\/interface com.scdev.reflection.ConcreteClass$ConcreteClassPublicInterface,\r\n\/\/class com.scdev.reflection.BaseClass$BaseClassInnerClass, \r\n\/\/class com.scdev.reflection.BaseClass$BaseClassMemberEnum]\r\nSystem.out.println(Arrays.toString(classes));\r\n<\/code><\/pre>\n<h3>\u30af\u30e9\u30b9\u3092\u5ba3\u8a00\u3059\u308b<\/h3>\n<p>getDeclaredClasses()\u30e1\u30bd\u30c3\u30c9\u306f\u3001\u3053\u306eClass\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u304c\u8868\u3059\u30af\u30e9\u30b9\u306e\u30e1\u30f3\u30d0\u30fc\u3068\u3057\u3066\u5ba3\u8a00\u3055\u308c\u305f\u3059\u3079\u3066\u306e\u30af\u30e9\u30b9\u3068\u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30fc\u30b9\u3092\u53cd\u6620\u3057\u305fClass\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306e\u914d\u5217\u3092\u8fd4\u3057\u307e\u3059\u3002\u8fd4\u3055\u308c\u308b\u914d\u5217\u306b\u306f\u3001\u7d99\u627f\u3055\u308c\u305f\u30af\u30e9\u30b9\u3084\u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30fc\u30b9\u3067\u5ba3\u8a00\u3055\u308c\u305f\u30af\u30e9\u30b9\u306f\u542b\u307e\u308c\u307e\u305b\u3093\u3002<\/p>\n<pre class=\"post-pre\"><code>\/\/getting all of the classes, interfaces, and enums that are explicitly declared in ConcreteClass\r\nClass&lt;?&gt;[] explicitClasses = Class.forName(\"com.scdev.reflection.ConcreteClass\").getDeclaredClasses();\r\n\/\/prints [class com.scdev.reflection.ConcreteClass$ConcreteClassDefaultClass, \r\n\/\/class com.scdev.reflection.ConcreteClass$ConcreteClassDefaultEnum, \r\n\/\/class com.scdev.reflection.ConcreteClass$ConcreteClassPrivateClass, \r\n\/\/class com.scdev.reflection.ConcreteClass$ConcreteClassProtectedClass, \r\n\/\/class com.scdev.reflection.ConcreteClass$ConcreteClassPublicClass, \r\n\/\/class com.scdev.reflection.ConcreteClass$ConcreteClassPublicEnum, \r\n\/\/interface com.scdev.reflection.ConcreteClass$ConcreteClassPublicInterface]\r\nSystem.out.println(Arrays.toString(explicitClasses));\r\n<\/code><\/pre>\n<h3>\u30af\u30e9\u30b9\u306e\u5ba3\u8a00\u3092\u53d6\u5f97<\/h3>\n<p>getDeclaringClass()\u30e1\u30bd\u30c3\u30c9\u306f\u3001\u305d\u308c\u304c\u5ba3\u8a00\u3055\u308c\u305f\u30af\u30e9\u30b9\u3092\u793a\u3059\u30af\u30e9\u30b9\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u3092\u8fd4\u3057\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code>Class&lt;?&gt; innerClass = Class.forName(\"com.scdev.reflection.ConcreteClass$ConcreteClassDefaultClass\");\r\n\/\/prints com.scdev.reflection.ConcreteClass\r\nSystem.out.println(innerClass.getDeclaringClass().getCanonicalName());\r\nSystem.out.println(innerClass.getEnclosingClass().getCanonicalName());\r\n<\/code><\/pre>\n<h3>\u30d1\u30c3\u30b1\u30fc\u30b8\u540d\u3092\u53d6\u5f97\u3059\u308b<\/h3>\n<p>getPackage() \u30e1\u30bd\u30c3\u30c9\u306f\u3001\u3053\u306e\u30af\u30e9\u30b9\u306e\u30d1\u30c3\u30b1\u30fc\u30b8\u3092\u8fd4\u3057\u307e\u3059\u3002\u3053\u306e\u30af\u30e9\u30b9\u306e\u30af\u30e9\u30b9\u30ed\u30fc\u30c0\u30fc\u304c\u30d1\u30c3\u30b1\u30fc\u30b8\u3092\u691c\u7d22\u3059\u308b\u305f\u3081\u306b\u4f7f\u7528\u3055\u308c\u307e\u3059\u3002\u30d1\u30c3\u30b1\u30fc\u30b8\u306e\u540d\u524d\u3092\u53d6\u5f97\u3059\u308b\u305f\u3081\u306b\u3001Package \u306e getName() \u30e1\u30bd\u30c3\u30c9\u3092\u547c\u3073\u51fa\u3059\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code>\/\/prints \"com.scdev.reflection\"\r\nSystem.out.println(Class.forName(\"com.scdev.reflection.BaseInterface\").getPackage().getName());\r\n<\/code><\/pre>\n<h3>\u30af\u30e9\u30b9\u4fee\u98fe\u5b50\u3092\u53d6\u5f97\u3059\u308b<\/h3>\n<p>getModifiers()\u30e1\u30bd\u30c3\u30c9\u306f\u3001\u30af\u30e9\u30b9\u4fee\u98fe\u5b50\u306eint\u8868\u73fe\u3092\u8fd4\u3057\u307e\u3059\u3002source code\u3067\u4f7f\u7528\u3055\u308c\u308b\u6587\u5b57\u5217\u5f62\u5f0f\u3067\u53d6\u5f97\u3059\u308b\u306b\u306f\u3001java.lang.reflect.Modifier.toString()\u30e1\u30bd\u30c3\u30c9\u3092\u4f7f\u7528\u3067\u304d\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code>System.out.println(Modifier.toString(concreteClass.getModifiers())); \/\/prints \"public\"\r\n\/\/prints \"public abstract interface\"\r\nSystem.out.println(Modifier.toString(Class.forName(\"com.scdev.reflection.BaseInterface\").getModifiers())); \r\n<\/code><\/pre>\n<h3>\u578b\u30d1\u30e9\u30e1\u30fc\u30bf\u3092\u53d6\u5f97<\/h3>\n<p>getTypeParameters()\u306f\u3001\u30af\u30e9\u30b9\u306b\u95a2\u9023\u4ed8\u3051\u3089\u308c\u3066\u3044\u308bType\u30d1\u30e9\u30e1\u30fc\u30bf\u30fc\u304c\u3042\u308b\u5834\u5408\u3001TypeVariable\u306e\u914d\u5217\u3092\u8fd4\u3057\u307e\u3059\u3002Type\u30d1\u30e9\u30e1\u30fc\u30bf\u30fc\u306f\u3001\u5ba3\u8a00\u3068\u540c\u3058\u9806\u5e8f\u3067\u8fd4\u3055\u308c\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code>\/\/Get Type parameters (generics)\r\nTypeVariable&lt;?&gt;[] typeParameters = Class.forName(\"java.util.HashMap\").getTypeParameters();\r\nfor(TypeVariable&lt;?&gt; t : typeParameters)\r\nSystem.out.print(t.getName()+\",\");\r\n<\/code><\/pre>\n<h3>\u5b9f\u88c5\u3055\u308c\u305f\u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30fc\u30b9\u3092\u53d6\u5f97\u3059\u308b<\/h3>\n<p>getGenericInterfaces()\u30e1\u30bd\u30c3\u30c9\u306f\u3001\u30b8\u30a7\u30cd\u30ea\u30c3\u30af\u578b\u60c5\u5831\u3092\u6301\u3064\u30af\u30e9\u30b9\u304c\u5b9f\u88c5\u3057\u3066\u3044\u308b\u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30fc\u30b9\u306e\u914d\u5217\u3092\u8fd4\u3057\u307e\u3059\u3002\u307e\u305f\u3001getInterfaces()\u3092\u4f7f\u7528\u3057\u3066\u3001\u5b9f\u88c5\u3055\u308c\u305f\u3059\u3079\u3066\u306e\u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30fc\u30b9\u306e\u30af\u30e9\u30b9\u8868\u73fe\u3092\u53d6\u5f97\u3059\u308b\u3053\u3068\u3082\u3067\u304d\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code>Type[] interfaces = Class.forName(\"java.util.HashMap\").getGenericInterfaces();\r\n\/\/prints \"[java.util.Map&lt;K, V&gt;, interface java.lang.Cloneable, interface java.io.Serializable]\"\r\nSystem.out.println(Arrays.toString(interfaces));\r\n\/\/prints \"[interface java.util.Map, interface java.lang.Cloneable, interface java.io.Serializable]\"\r\nSystem.out.println(Arrays.toString(Class.forName(\"java.util.HashMap\").getInterfaces()));\t\t\r\n<\/code><\/pre>\n<h3>\u3059\u3079\u3066\u306e\u516c\u958b\u30e1\u30bd\u30c3\u30c9\u3092\u53d6\u5f97\u3059\u308b<\/h3>\n<p>getMethods()\u30e1\u30bd\u30c3\u30c9\u306f\u3001\u30b9\u30fc\u30d1\u30fc\u30af\u30e9\u30b9\u3084\u30b9\u30fc\u30d1\u30fc\u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30fc\u30b9\u306e\u30d1\u30d6\u30ea\u30c3\u30af\u30e1\u30bd\u30c3\u30c9\u3092\u542b\u3080\u30af\u30e9\u30b9\u306e\u30d1\u30d6\u30ea\u30c3\u30af\u30e1\u30bd\u30c3\u30c9\u306e\u914d\u5217\u3092\u8fd4\u3057\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code>Method[] publicMethods = Class.forName(\"com.scdev.reflection.ConcreteClass\").getMethods();\r\n\/\/prints public methods of ConcreteClass, BaseClass, Object\r\nSystem.out.println(Arrays.toString(publicMethods));\r\n<\/code><\/pre>\n<h3>\u3059\u3079\u3066\u306e\u516c\u958b\u30b3\u30f3\u30b9\u30c8\u30e9\u30af\u30bf\u30fc\u3092\u53d6\u5f97\u3059\u308b<\/h3>\n<p>getConstructors() \u30e1\u30bd\u30c3\u30c9\u306f\u3001\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306e\u30af\u30e9\u30b9\u53c2\u7167\u306e\u516c\u958b\u3055\u308c\u305f\u30b3\u30f3\u30b9\u30c8\u30e9\u30af\u30bf\u306e\u30ea\u30b9\u30c8\u3092\u8fd4\u3057\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code>\/\/Get All public constructors\r\nConstructor&lt;?&gt;[] publicConstructors = Class.forName(\"com.scdev.reflection.ConcreteClass\").getConstructors();\r\n\/\/prints public constructors of ConcreteClass\r\nSystem.out.println(Arrays.toString(publicConstructors));\r\n<\/code><\/pre>\n<h3>\u3059\u3079\u3066\u306e\u516c\u958b\u30d5\u30a3\u30fc\u30eb\u30c9\u3092\u53d6\u5f97\u3059\u308b<\/h3>\n<p>getFields()\u30e1\u30bd\u30c3\u30c9\u306f\u3001\u81ea\u8eab\u306e\u30b9\u30fc\u30d1\u30fc\u30af\u30e9\u30b9\u3068\u30b9\u30fc\u30d1\u30fc\u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30fc\u30b9\u306e\u30d1\u30d6\u30ea\u30c3\u30af\u30d5\u30a3\u30fc\u30eb\u30c9\u3092\u542b\u3080\u30af\u30e9\u30b9\u306e\u914d\u5217\u3092\u8fd4\u3057\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code>\/\/Get All public fields\r\nField[] publicFields = Class.forName(\"com.scdev.reflection.ConcreteClass\").getFields();\r\n\/\/prints public fields of ConcreteClass, it's superclass and super interfaces\r\nSystem.out.println(Arrays.toString(publicFields));\r\n<\/code><\/pre>\n<h3>\u3059\u3079\u3066\u306e\u6ce8\u91c8\u3092\u53d6\u5f97\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/h3>\n<p>getAnnotations()\u30e1\u30bd\u30c3\u30c9\u306f\u3001\u8981\u7d20\u306e\u3059\u3079\u3066\u306e\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u3092\u8fd4\u3057\u307e\u3059\u3002\u30af\u30e9\u30b9\u3001\u30d5\u30a3\u30fc\u30eb\u30c9\u3001\u30e1\u30bd\u30c3\u30c9\u3067\u3082\u4f7f\u7528\u3067\u304d\u307e\u3059\u3002\u305f\u3060\u3057\u3001\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u3067\u5229\u7528\u53ef\u80fd\u306a\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u306f\u3001\u5b9f\u884c\u6642\u306e\u4fdd\u6301\u65b9\u91dd\u3067\u3042\u308b\u3053\u3068\u306b\u6ce8\u610f\u3057\u3066\u304f\u3060\u3055\u3044\u3002Java\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb\u3092\u53c2\u7167\u3057\u3066\u304f\u3060\u3055\u3044\u3002\u5f8c\u306e\u30bb\u30af\u30b7\u30e7\u30f3\u3067\u8a73\u3057\u304f\u8abf\u3079\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code>java.lang.annotation.Annotation[] annotations = Class.forName(\"com.scdev.reflection.ConcreteClass\").getAnnotations();\r\n\/\/prints [@java.lang.Deprecated()]\r\nSystem.out.println(Arrays.toString(annotations));\r\n<\/code><\/pre>\n<ol>\u30d5\u30a3\u30fc\u30eb\u30c9\u306b\u5bfe\u3059\u308bJava\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3<\/ol>\n<p>Reflection API\u306f\u3001\u30af\u30e9\u30b9\u306e\u30d5\u30a3\u30fc\u30eb\u30c9\u3092\u5206\u6790\u3057\u3001\u5b9f\u884c\u6642\u306b\u5024\u3092\u5909\u66f4\u3059\u308b\u305f\u3081\u306e\u3044\u304f\u3064\u304b\u306e\u30e1\u30bd\u30c3\u30c9\u3092\u63d0\u4f9b\u3057\u3066\u3044\u307e\u3059\u3002\u3053\u306e\u30bb\u30af\u30b7\u30e7\u30f3\u3067\u306f\u3001\u30e1\u30bd\u30c3\u30c9\u306b\u95a2\u3059\u308b\u4e00\u822c\u7684\u306b\u4f7f\u7528\u3055\u308c\u308b\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u6a5f\u80fd\u306e\u3044\u304f\u3064\u304b\u3092\u898b\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n<h3>\u516c\u958b\u30d5\u30a3\u30fc\u30eb\u30c9\u3092\u53d6\u5f97\u3059\u308b\u3002<\/h3>\n<p>\u524d\u306e\u30bb\u30af\u30b7\u30e7\u30f3\u3067\u306f\u3001\u30af\u30e9\u30b9\u306e\u3059\u3079\u3066\u306e\u30d1\u30d6\u30ea\u30c3\u30af\u30d5\u30a3\u30fc\u30eb\u30c9\u306e\u30ea\u30b9\u30c8\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u306b\u3064\u3044\u3066\u8aac\u660e\u3057\u307e\u3057\u305f\u3002Reflection API\u306f\u3001getField()\u30e1\u30bd\u30c3\u30c9\u3092\u4ecb\u3057\u3066\u30af\u30e9\u30b9\u306e\u7279\u5b9a\u306e\u30d1\u30d6\u30ea\u30c3\u30af\u30d5\u30a3\u30fc\u30eb\u30c9\u3092\u53d6\u5f97\u3059\u308b\u305f\u3081\u306e\u30e1\u30bd\u30c3\u30c9\u3082\u63d0\u4f9b\u3057\u3066\u3044\u307e\u3059\u3002\u3053\u306e\u30e1\u30bd\u30c3\u30c9\u306f\u3001\u6307\u5b9a\u3055\u308c\u305f\u30af\u30e9\u30b9\u53c2\u7167\u3001\u30b9\u30fc\u30d1\u30fc\u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30fc\u30b9\u3001\u305d\u3057\u3066\u30b9\u30fc\u30d1\u30fc\u30af\u30e9\u30b9\u306e\u9806\u306b\u30d5\u30a3\u30fc\u30eb\u30c9\u3092\u691c\u7d22\u3057\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code>Field field = Class.forName(\"com.scdev.reflection.ConcreteClass\").getField(\"interfaceInt\");\r\n<\/code><\/pre>\n<p>\u4e0a\u8a18\u306e\u547c\u3073\u51fa\u3057\u306f\u3001ConcreteClass\u306b\u3088\u3063\u3066\u5b9f\u88c5\u3055\u308c\u305fBaseInterface\u306e\u30d5\u30a3\u30fc\u30eb\u30c9\u3092\u8fd4\u3057\u307e\u3059\u3002\u30d5\u30a3\u30fc\u30eb\u30c9\u304c\u898b\u3064\u304b\u3089\u306a\u3044\u5834\u5408\u306f\u3001NoSuchFieldException\u304c\u30b9\u30ed\u30fc\u3055\u308c\u307e\u3059\u3002<\/p>\n<h3>\u30af\u30e9\u30b9\u3092\u5ba3\u8a00\u3059\u308b\u30d5\u30a3\u30fc\u30eb\u30c9<\/h3>\n<p>field\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306egetDeclaringClass()\u3092\u4f7f\u7528\u3059\u308b\u3053\u3068\u3067\u3001\u30d5\u30a3\u30fc\u30eb\u30c9\u3092\u5ba3\u8a00\u3057\u3066\u3044\u308b\u30af\u30e9\u30b9\u3092\u53d6\u5f97\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code>try {\r\n\tField field = Class.forName(\"com.scdev.reflection.ConcreteClass\").getField(\"interfaceInt\");\r\n\tClass&lt;?&gt; fieldClass = field.getDeclaringClass();\r\n\tSystem.out.println(fieldClass.getCanonicalName()); \/\/prints com.scdev.reflection.BaseInterface\r\n} catch (NoSuchFieldException | SecurityException e) {\r\n\te.printStackTrace();\r\n}\r\n<\/code><\/pre>\n<h3>\u30d5\u30a3\u30fc\u30eb\u30c9\u306e\u30bf\u30a4\u30d7\u3092\u53d6\u5f97\u3059\u308b<\/h3>\n<p>getType()\u30e1\u30bd\u30c3\u30c9\u306f\u3001\u5ba3\u8a00\u3055\u308c\u305f\u30d5\u30a3\u30fc\u30eb\u30c9\u306e\u578b\u306b\u5bfe\u5fdc\u3059\u308bClass\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u3092\u8fd4\u3057\u307e\u3059\u3002\u3082\u3057\u30d5\u30a3\u30fc\u30eb\u30c9\u304c\u30d7\u30ea\u30df\u30c6\u30a3\u30d6\u578b\u3067\u3042\u308b\u5834\u5408\u3001\u30e9\u30c3\u30d1\u30fc\u30af\u30e9\u30b9\u306e\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u3092\u8fd4\u3057\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code>Field field = Class.forName(\"com.scdev.reflection.ConcreteClass\").getField(\"publicInt\");\r\nClass&lt;?&gt; fieldType = field.getType();\r\nSystem.out.println(fieldType.getCanonicalName()); \/\/prints int\t\t\t\r\n<\/code><\/pre>\n<h3>\u30d1\u30d6\u30ea\u30c3\u30af\u30d5\u30a3\u30fc\u30eb\u30c9\u306e\u5024\u3092\u53d6\u5f97\/\u8a2d\u5b9a\u3059\u308b<\/h3>\n<p>\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u3092\u4f7f\u3063\u3066\u3001\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306e\u30d5\u30a3\u30fc\u30eb\u30c9\u306e\u5024\u3092\u53d6\u5f97\u3057\u305f\u308a\u8a2d\u5b9a\u3057\u305f\u308a\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code>Field field = Class.forName(\"com.scdev.reflection.ConcreteClass\").getField(\"publicInt\");\r\nConcreteClass obj = new ConcreteClass(5);\r\nSystem.out.println(field.get(obj)); \/\/prints 5\r\nfield.setInt(obj, 10); \/\/setting field value to 10 in object\r\nSystem.out.println(field.get(obj)); \/\/prints 10\r\n<\/code><\/pre>\n<p>get()\u30e1\u30bd\u30c3\u30c9\u306f\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u3092\u8fd4\u3059\u305f\u3081\u3001\u30d5\u30a3\u30fc\u30eb\u30c9\u304c\u30d7\u30ea\u30df\u30c6\u30a3\u30d6\u578b\u3067\u3042\u308c\u3070\u3001\u305d\u308c\u306b\u5bfe\u5fdc\u3059\u308b\u30e9\u30c3\u30d1\u30fc\u30af\u30e9\u30b9\u3092\u8fd4\u3057\u307e\u3059\u3002\u30d5\u30a3\u30fc\u30eb\u30c9\u304c\u9759\u7684\u3067\u3042\u308b\u5834\u5408\u3001get()\u30e1\u30bd\u30c3\u30c9\u306b\u306f\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u3092null\u3068\u3057\u3066\u6e21\u3059\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u30d5\u30a3\u30fc\u30eb\u30c9\u306b\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u3092\u8a2d\u5b9a\u3059\u308b\u305f\u3081\u306e\u3044\u304f\u3064\u304b\u306eset*()\u30e1\u30bd\u30c3\u30c9\u304c\u3042\u308a\u3001\u30d5\u30a3\u30fc\u30eb\u30c9\u306b\u7570\u306a\u308b\u578b\u306e\u30d7\u30ea\u30df\u30c6\u30a3\u30d6\u578b\u3092\u8a2d\u5b9a\u3059\u308b\u3053\u3068\u3082\u3067\u304d\u307e\u3059\u3002\u30d5\u30a3\u30fc\u30eb\u30c9\u306e\u578b\u3092\u53d6\u5f97\u3057\u3001\u9069\u5207\u306a\u95a2\u6570\u3092\u547c\u3073\u51fa\u3057\u3066\u30d5\u30a3\u30fc\u30eb\u30c9\u306e\u5024\u3092\u6b63\u3057\u304f\u8a2d\u5b9a\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u30d5\u30a3\u30fc\u30eb\u30c9\u304cfinal\u3067\u3042\u308b\u5834\u5408\u3001set()\u30e1\u30bd\u30c3\u30c9\u306fjava.lang.IllegalAccessException\u3092\u30b9\u30ed\u30fc\u3057\u307e\u3059\u3002<\/p>\n<h3>\u30d7\u30e9\u30a4\u30d9\u30fc\u30c8\u30d5\u30a3\u30fc\u30eb\u30c9\u306e\u5024\u3092\u53d6\u5f97\/\u8a2d\u5b9a\u3059\u308b<\/h3>\n<p>\u30af\u30e9\u30b9\u306e\u5916\u90e8\u304b\u3089\u306f\u30d7\u30e9\u30a4\u30d9\u30fc\u30c8\u306a\u30d5\u30a3\u30fc\u30eb\u30c9\u3084\u30e1\u30bd\u30c3\u30c9\u306b\u306f\u30a2\u30af\u30bb\u30b9\u3067\u304d\u306a\u3044\u3068\u3044\u3046\u3053\u3068\u306f\u308f\u304b\u3063\u3066\u3044\u307e\u3059\u304c\u3001\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u3092\u4f7f\u7528\u3059\u308b\u3053\u3068\u3067\u3001\u30d5\u30a3\u30fc\u30eb\u30c9\u4fee\u98fe\u5b50\u306eJava\u30a2\u30af\u30bb\u30b9\u30c1\u30a7\u30c3\u30af\u3092\u30aa\u30d5\u306b\u3057\u3066\u3001\u30d7\u30e9\u30a4\u30d9\u30fc\u30c8\u30d5\u30a3\u30fc\u30eb\u30c9\u306e\u5024\u3092\u53d6\u5f97\u307e\u305f\u306f\u8a2d\u5b9a\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code>Field privateField = Class.forName(\"com.scdev.reflection.ConcreteClass\").getDeclaredField(\"privateString\");\r\n\/\/turning off access check with below method call\r\nprivateField.setAccessible(true);\r\nConcreteClass objTest = new ConcreteClass(1);\r\nSystem.out.println(privateField.get(objTest)); \/\/ prints \"private string\"\r\nprivateField.set(objTest, \"private string updated\");\r\nSystem.out.println(privateField.get(objTest)); \/\/prints \"private string updated\"\r\n<\/code><\/pre>\n<ol>\u30e1\u30bd\u30c3\u30c9\u306e\u305f\u3081\u306eJava\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3<\/ol>\n<p>\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u3092\u4f7f\u7528\u3059\u308b\u3053\u3068\u3067\u3001\u30e1\u30bd\u30c3\u30c9\u306b\u95a2\u3059\u308b\u60c5\u5831\u3092\u53d6\u5f97\u3057\u3001\u30e1\u30bd\u30c3\u30c9\u3092\u5b9f\u884c\u3059\u308b\u3053\u3068\u3082\u3067\u304d\u307e\u3059\u3002\u3053\u306e\u30bb\u30af\u30b7\u30e7\u30f3\u3067\u306f\u3001\u30e1\u30bd\u30c3\u30c9\u3092\u53d6\u5f97\u3059\u308b\u305f\u3081\u306e\u7570\u306a\u308b\u65b9\u6cd5\u3001\u30e1\u30bd\u30c3\u30c9\u3092\u5b9f\u884c\u3059\u308b\u65b9\u6cd5\u3001\u304a\u3088\u3073\u30d7\u30e9\u30a4\u30d9\u30fc\u30c8\u30e1\u30bd\u30c3\u30c9\u306b\u30a2\u30af\u30bb\u30b9\u3059\u308b\u65b9\u6cd5\u306b\u3064\u3044\u3066\u5b66\u3073\u307e\u3059\u3002<\/p>\n<h3>\u516c\u958b\u3055\u308c\u305f\u30e1\u30bd\u30c3\u30c9\u3092\u53d6\u5f97<\/h3>\n<p>\u30af\u30e9\u30b9\u306epublic\u306a\u30e1\u30bd\u30c3\u30c9\u3092\u53d6\u5f97\u3059\u308b\u306b\u306f\u3001getMethod()\u3092\u4f7f\u7528\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u30e1\u30bd\u30c3\u30c9\u540d\u3068\u30e1\u30bd\u30c3\u30c9\u306e\u30d1\u30e9\u30e1\u30fc\u30bf\u30fc\u306e\u578b\u3092\u6e21\u3059\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002\u3082\u3057\u30af\u30e9\u30b9\u5185\u3067\u305d\u306e\u30e1\u30bd\u30c3\u30c9\u304c\u898b\u3064\u304b\u3089\u306a\u3044\u5834\u5408\u3001\u53cd\u5c04API\u306f\u30b9\u30fc\u30d1\u30fc\u30af\u30e9\u30b9\u3067\u305d\u306e\u30e1\u30bd\u30c3\u30c9\u3092\u63a2\u3057\u307e\u3059\u3002\u4ee5\u4e0b\u306e\u4f8b\u3067\u306f\u3001HashMap\u306eput()\u30e1\u30bd\u30c3\u30c9\u3092\u53cd\u5c04\u3092\u4f7f\u3063\u3066\u53d6\u5f97\u3057\u3066\u3044\u307e\u3059\u3002\u307e\u305f\u3001\u4f8b\u3067\u306f\u30e1\u30bd\u30c3\u30c9\u306e\u30d1\u30e9\u30e1\u30fc\u30bf\u30fc\u306e\u578b\u3001\u30e1\u30bd\u30c3\u30c9\u306e\u4fee\u98fe\u5b50\u3001\u623b\u308a\u5024\u306e\u578b\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u3082\u793a\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code>Method method = Class.forName(\"java.util.HashMap\").getMethod(\"put\", Object.class, Object.class);\r\n\/\/get method parameter types, prints \"[class java.lang.Object, class java.lang.Object]\"\r\nSystem.out.println(Arrays.toString(method.getParameterTypes()));\r\n\/\/get method return type, return \"class java.lang.Object\", class reference for void\r\nSystem.out.println(method.getReturnType());\r\n\/\/get method modifiers\r\nSystem.out.println(Modifier.toString(method.getModifiers())); \/\/prints \"public\"\r\n<\/code><\/pre>\n<h3>\u516c\u958b\u30e1\u30bd\u30c3\u30c9\u306e\u547c\u3073\u51fa\u3057<\/h3>\n<p>\u4ee5\u4e0b\u306e\u30b3\u30fc\u30c9\u306e\u4f8b\u3067\u306f\u3001\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u3092\u4f7f\u7528\u3057\u3066HashMap\u306eput\u30e1\u30bd\u30c3\u30c9\u3092\u547c\u3073\u51fa\u3059\u305f\u3081\u306b\u3001Method\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306einvoke()\u30e1\u30bd\u30c3\u30c9\u3092\u4f7f\u7528\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code>Method method = Class.forName(\"java.util.HashMap\").getMethod(\"put\", Object.class, Object.class);\r\nMap&lt;String, String&gt; hm = new HashMap&lt;&gt;();\r\nmethod.invoke(hm, \"key\", \"value\");\r\nSystem.out.println(hm); \/\/ prints {key=value}\r\n<\/code><\/pre>\n<p>\u3082\u3057\u30e1\u30bd\u30c3\u30c9\u304c\u9759\u7684\u306a\u5834\u5408\u3001\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u5f15\u6570\u3068\u3057\u3066NULL\u3092\u6e21\u3059\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<h3>\u30d7\u30e9\u30a4\u30d9\u30fc\u30c8\u30e1\u30bd\u30c3\u30c9\u3092\u547c\u3073\u51fa\u3059\u3002<\/h3>\n<p>\u79c1\u305f\u3061\u306f\u3001getDeclaredMethod\uff08\uff09\u3092\u4f7f\u7528\u3057\u3066\u975e\u516c\u958b\u306e\u30e1\u30bd\u30c3\u30c9\u3092\u53d6\u5f97\u3057\u3001\u30a2\u30af\u30bb\u30b9\u30c1\u30a7\u30c3\u30af\u3092\u30aa\u30d5\u306b\u3057\u3066\u547c\u3073\u51fa\u3059\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u4ee5\u4e0b\u306e\u4f8b\u306f\u3001\u30d1\u30e9\u30e1\u30fc\u30bf\u304c\u306a\u304f\u3001\u9759\u7684\u306aBaseClass\u306emethod3\uff08\uff09\u3092\u547c\u3073\u51fa\u3059\u65b9\u6cd5\u3092\u793a\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code>\/\/invoking private method\r\nMethod method = Class.forName(\"com.scdev.reflection.BaseClass\").getDeclaredMethod(\"method3\", null);\r\nmethod.setAccessible(true);\r\nmethod.invoke(null, null); \/\/prints \"Method3\"\r\n<\/code><\/pre>\n<ol>\u30b3\u30f3\u30b9\u30c8\u30e9\u30af\u30bf\u306e\u305f\u3081\u306eJava\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3<\/ol>\n<p>Reflector API\u306f\u3001\u30af\u30e9\u30b9\u306e\u30b3\u30f3\u30b9\u30c8\u30e9\u30af\u30bf\u3092\u5206\u6790\u3059\u308b\u305f\u3081\u306e\u30e1\u30bd\u30c3\u30c9\u3092\u63d0\u4f9b\u3057\u3001\u30b3\u30f3\u30b9\u30c8\u30e9\u30af\u30bf\u3092\u547c\u3073\u51fa\u3059\u3053\u3068\u3067\u65b0\u3057\u3044\u30af\u30e9\u30b9\u306e\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u4f5c\u6210\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u3059\u3067\u306b\u516c\u958b\u3055\u308c\u3066\u3044\u308b\u3059\u3079\u3066\u306e\u30b3\u30f3\u30b9\u30c8\u30e9\u30af\u30bf\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u306b\u3064\u3044\u3066\u306f\u3001\u3059\u3067\u306b\u5b66\u3093\u3067\u3044\u307e\u3059\u3002<\/p>\n<h3>\u516c\u958b\u3055\u308c\u305f\u30b3\u30f3\u30b9\u30c8\u30e9\u30af\u30bf\u30fc\u3092\u53d6\u5f97\u3059\u308b<\/h3>\n<p>\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306e\u30af\u30e9\u30b9\u8868\u73fe\u306b\u5bfe\u3057\u3066\u3001getConstructor()\u30e1\u30bd\u30c3\u30c9\u3092\u4f7f\u7528\u3057\u3066\u7279\u5b9a\u306e\u516c\u958b\u3055\u308c\u305f\u30b3\u30f3\u30b9\u30c8\u30e9\u30af\u30bf\u3092\u53d6\u5f97\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u4ee5\u4e0b\u306e\u4f8b\u306f\u3001\u4e0a\u8a18\u3067\u5b9a\u7fa9\u3055\u308c\u305fConcreteClass\u306e\u30b3\u30f3\u30b9\u30c8\u30e9\u30af\u30bf\u3068HashMap\u306e\u5f15\u6570\u306a\u3057\u306e\u30b3\u30f3\u30b9\u30c8\u30e9\u30af\u30bf\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u3092\u793a\u3057\u3066\u3044\u307e\u3059\u3002\u3055\u3089\u306b\u3001\u30b3\u30f3\u30b9\u30c8\u30e9\u30af\u30bf\u306e\u30d1\u30e9\u30e1\u30fc\u30bf\u30fc\u30bf\u30a4\u30d7\u306e\u914d\u5217\u3092\u53d6\u5f97\u3059\u308b\u65b9\u6cd5\u3082\u793a\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code>Constructor&lt;?&gt; constructor = Class.forName(\"com.scdev.reflection.ConcreteClass\").getConstructor(int.class);\r\n\/\/getting constructor parameters\r\nSystem.out.println(Arrays.toString(constructor.getParameterTypes())); \/\/ prints \"[int]\"\r\n\t\t\r\nConstructor&lt;?&gt; hashMapConstructor = Class.forName(\"java.util.HashMap\").getConstructor(null);\r\nSystem.out.println(Arrays.toString(hashMapConstructor.getParameterTypes())); \/\/ prints \"[]\"\r\n<\/code><\/pre>\n<h3>\u30b3\u30f3\u30b9\u30c8\u30e9\u30af\u30bf\u3092\u4f7f\u7528\u3057\u3066\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u3092\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u5316\u3059\u308b\u3002<\/h3>\n<p>\u30af\u30e9\u30b9\u306e\u65b0\u3057\u3044\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u4f5c\u6210\u3059\u308b\u305f\u3081\u306b\u3001newInstance\uff08\uff09\u30e1\u30bd\u30c3\u30c9\u3092\u30b3\u30f3\u30b9\u30c8\u30e9\u30af\u30bf\u30aa\u30d6\u30b8\u30a7\u30af\u30c8\u306b\u4f7f\u7528\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u30b3\u30f3\u30d1\u30a4\u30eb\u6642\u306b\u30af\u30e9\u30b9\u306e\u60c5\u5831\u3092\u6301\u3063\u3066\u3044\u306a\u3044\u5834\u5408\u306b\u306f\u3001\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u3092\u4f7f\u7528\u3057\u3066Object\u306b\u5272\u308a\u5f53\u3066\u3001\u3055\u3089\u306b\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u3092\u4f7f\u7528\u3057\u3066\u30d5\u30a3\u30fc\u30eb\u30c9\u306b\u30a2\u30af\u30bb\u30b9\u3057\u3001\u30e1\u30bd\u30c3\u30c9\u3092\u547c\u3073\u51fa\u3059\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<pre class=\"post-pre\"><code>Constructor&lt;?&gt; constructor = Class.forName(\"com.scdev.reflection.ConcreteClass\").getConstructor(int.class);\r\n\/\/getting constructor parameters\r\nSystem.out.println(Arrays.toString(constructor.getParameterTypes())); \/\/ prints \"[int]\"\r\n\t\t\r\nObject myObj = constructor.newInstance(10);\r\nMethod myObjMethod = myObj.getClass().getMethod(\"method1\", null);\r\nmyObjMethod.invoke(myObj, null); \/\/prints \"Method1 impl.\"\r\n\r\nConstructor&lt;?&gt; hashMapConstructor = Class.forName(\"java.util.HashMap\").getConstructor(null);\r\nSystem.out.println(Arrays.toString(hashMapConstructor.getParameterTypes())); \/\/ prints \"[]\"\r\nHashMap&lt;String,String&gt; myMap = (HashMap&lt;String,String&gt;) hashMapConstructor.newInstance(null);\r\n<\/code><\/pre>\n<ol>\u6ce8\u91c8\u306e\u305f\u3081\u306e\u53cd\u7701<\/ol>\n<p>\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u306f\u3001Java 1.5\u3067\u5c0e\u5165\u3055\u308c\u3001\u30af\u30e9\u30b9\u3001\u30e1\u30bd\u30c3\u30c9\u3001\u30d5\u30a3\u30fc\u30eb\u30c9\u306e\u30e1\u30bf\u30c7\u30fc\u30bf\u60c5\u5831\u3092\u63d0\u4f9b\u3059\u308b\u305f\u3081\u306b\u4f7f\u7528\u3055\u308c\u3001\u73fe\u5728\u3067\u306fSpring\u3084Hibernate\u306a\u3069\u306e\u30d5\u30ec\u30fc\u30e0\u30ef\u30fc\u30af\u3067\u5e83\u304f\u4f7f\u7528\u3055\u308c\u3066\u3044\u307e\u3059\u3002\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3API\u3082\u62e1\u5f35\u3055\u308c\u3001\u5b9f\u884c\u6642\u306b\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u3092\u5206\u6790\u3059\u308b\u305f\u3081\u306e\u30b5\u30dd\u30fc\u30c8\u3092\u63d0\u4f9b\u3057\u3066\u3044\u307e\u3059\u3002\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3API\u3092\u4f7f\u7528\u3059\u308b\u3053\u3068\u3067\u3001Retention\u30dd\u30ea\u30b7\u30fc\u304cRuntime\u3067\u3042\u308b\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u3092\u5206\u6790\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u79c1\u306f\u3059\u3067\u306b\u8a73\u7d30\u306a\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb\u3092\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u3068\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3API\u3092\u4f7f\u7528\u3057\u3066\u30d1\u30fc\u30b9\u3059\u308b\u65b9\u6cd5\u306b\u3064\u3044\u3066\u66f8\u3044\u3066\u3044\u307e\u3059\u306e\u3067\u3001Java\u30a2\u30ce\u30c6\u30fc\u30b7\u30e7\u30f3\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb\u3092\u3054\u89a7\u3044\u305f\u3060\u304f\u3053\u3068\u3092\u304a\u3059\u3059\u3081\u3057\u307e\u3059\u3002\u3053\u308c\u3067Java\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306e\u4f8b\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb\u306f\u4ee5\u4e0a\u3067\u3059\u3002\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb\u304c\u304a\u6c17\u306b\u5165\u308a\u306b\u306a\u308a\u3001Java\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3API\u306e\u91cd\u8981\u6027\u304c\u7406\u89e3\u3067\u304d\u305f\u3053\u3068\u3092\u9858\u3063\u3066\u3044\u307e\u3059\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306f\u3001\u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u306e\u5b9f\u884c\u6642\u306e\u632f\u308b\u821e\u3044\u3092\u691c\u67fb\u304a\u3088\u3073\u5909\u66f4\u3059\u308b\u6a5f\u80fd\u3092\u63d0\u4f9b\u3057\u307e\u3059\u3002Java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306f\u3001\u30b3\u30a2Java\u306e\u9ad8\u5ea6\u306a\u30c8\u30d4\u30c3\u30af\u306e1\u3064\u3067\u3059\u3002Java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u3092\u4f7f\u7528\u3059\u308b\u3068\u3001\u30b3\u30f3\u30d1\u30a4\u30eb\u6642\u306b [&hellip;]<\/p>\n","protected":false},"author":9,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[26,61],"class_list":["post-654","post","type-post","status-publish","format-standard","hentry","category-uncategorized","tag-26","tag-61"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v21.5 (Yoast SEO v21.5) - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306e\u4f8b\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb - Blog - Silicon Cloud<\/title>\n<meta name=\"description\" content=\"Java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306e\u4f8b\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb\u3092\u5206\u304b\u308a\u3084\u3059\u304f\u89e3\u8aac\u3002\u5b9f\u8df5\u7684\u306a\u4f8b\u3068\u30b3\u30fc\u30c9\u3001\u6ce8\u610f\u70b9\u3092\u542b\u3081\u3066\u521d\u5fc3\u8005\u306b\u3082\u7406\u89e3\u3067\u304d\u308b\u3088\u3046\u8aac\u660e\u3057\u307e\u3059\u3002\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.silicloud.com\/ja\/blog\/java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306e\u4f8b\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb\/\" \/>\n<meta property=\"og:locale\" content=\"ja_JP\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306e\u4f8b\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb\" \/>\n<meta property=\"og:description\" content=\"Java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306e\u4f8b\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb\u3092\u5206\u304b\u308a\u3084\u3059\u304f\u89e3\u8aac\u3002\u5b9f\u8df5\u7684\u306a\u4f8b\u3068\u30b3\u30fc\u30c9\u3001\u6ce8\u610f\u70b9\u3092\u542b\u3081\u3066\u521d\u5fc3\u8005\u306b\u3082\u7406\u89e3\u3067\u304d\u308b\u3088\u3046\u8aac\u660e\u3057\u307e\u3059\u3002\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.silicloud.com\/ja\/blog\/java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306e\u4f8b\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb\/\" \/>\n<meta property=\"og:site_name\" content=\"Blog - Silicon Cloud\" \/>\n<meta property=\"article:published_time\" content=\"2023-09-11T18:17:59+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-07-31T16:24:33+00:00\" \/>\n<meta name=\"author\" content=\"\u590f\u6a39, \u98a8\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u57f7\u7b46\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"\u590f\u6a39, \u98a8\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u63a8\u5b9a\u8aad\u307f\u53d6\u308a\u6642\u9593\" \/>\n\t<meta name=\"twitter:data2\" content=\"42\u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%ae%e3%83%aa%e3%83%95%e3%83%ac%e3%82%af%e3%82%b7%e3%83%a7%e3%83%b3%e3%81%ae%e4%be%8b%e3%81%ae%e3%83%81%e3%83%a5%e3%83%bc%e3%83%88%e3%83%aa%e3%82%a2%e3%83%ab\/\",\"url\":\"https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%ae%e3%83%aa%e3%83%95%e3%83%ac%e3%82%af%e3%82%b7%e3%83%a7%e3%83%b3%e3%81%ae%e4%be%8b%e3%81%ae%e3%83%81%e3%83%a5%e3%83%bc%e3%83%88%e3%83%aa%e3%82%a2%e3%83%ab\/\",\"name\":\"Java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306e\u4f8b\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb - Blog - Silicon Cloud\",\"isPartOf\":{\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/#website\"},\"datePublished\":\"2023-09-11T18:17:59+00:00\",\"dateModified\":\"2025-07-31T16:24:33+00:00\",\"author\":{\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/#\/schema\/person\/4e591db2661c4cc425470b461259391d\"},\"description\":\"Java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306e\u4f8b\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb\u3092\u5206\u304b\u308a\u3084\u3059\u304f\u89e3\u8aac\u3002\u5b9f\u8df5\u7684\u306a\u4f8b\u3068\u30b3\u30fc\u30c9\u3001\u6ce8\u610f\u70b9\u3092\u542b\u3081\u3066\u521d\u5fc3\u8005\u306b\u3082\u7406\u89e3\u3067\u304d\u308b\u3088\u3046\u8aac\u660e\u3057\u307e\u3059\u3002\",\"breadcrumb\":{\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%ae%e3%83%aa%e3%83%95%e3%83%ac%e3%82%af%e3%82%b7%e3%83%a7%e3%83%b3%e3%81%ae%e4%be%8b%e3%81%ae%e3%83%81%e3%83%a5%e3%83%bc%e3%83%88%e3%83%aa%e3%82%a2%e3%83%ab\/#breadcrumb\"},\"inLanguage\":\"ja\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%ae%e3%83%aa%e3%83%95%e3%83%ac%e3%82%af%e3%82%b7%e3%83%a7%e3%83%b3%e3%81%ae%e4%be%8b%e3%81%ae%e3%83%81%e3%83%a5%e3%83%bc%e3%83%88%e3%83%aa%e3%82%a2%e3%83%ab\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%ae%e3%83%aa%e3%83%95%e3%83%ac%e3%82%af%e3%82%b7%e3%83%a7%e3%83%b3%e3%81%ae%e4%be%8b%e3%81%ae%e3%83%81%e3%83%a5%e3%83%bc%e3%83%88%e3%83%aa%e3%82%a2%e3%83%ab\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/www.silicloud.com\/ja\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306e\u4f8b\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/#website\",\"url\":\"https:\/\/www.silicloud.com\/ja\/blog\/\",\"name\":\"Blog - Silicon Cloud\",\"description\":\"\",\"inLanguage\":\"ja\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/#\/schema\/person\/4e591db2661c4cc425470b461259391d\",\"name\":\"\u590f\u6a39, \u98a8\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"ja\",\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/65e0ff40534461b1fa000382dc194e1716f793ab0bcb218ac3c40895551a08c5?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/65e0ff40534461b1fa000382dc194e1716f793ab0bcb218ac3c40895551a08c5?s=96&d=mm&r=g\",\"caption\":\"\u590f\u6a39, \u98a8\"},\"url\":\"https:\/\/www.silicloud.com\/ja\/blog\/author\/natsukikaze\/\"},{\"@type\":\"ImageObject\",\"inLanguage\":\"ja\",\"@id\":\"https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%ae%e3%83%aa%e3%83%95%e3%83%ac%e3%82%af%e3%82%b7%e3%83%a7%e3%83%b3%e3%81%ae%e4%be%8b%e3%81%ae%e3%83%81%e3%83%a5%e3%83%bc%e3%83%88%e3%83%aa%e3%82%a2%e3%83%ab\/#local-main-organization-logo\",\"url\":\"\",\"contentUrl\":\"\",\"caption\":\"Blog - Silicon Cloud\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306e\u4f8b\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb - Blog - Silicon Cloud","description":"Java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306e\u4f8b\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb\u3092\u5206\u304b\u308a\u3084\u3059\u304f\u89e3\u8aac\u3002\u5b9f\u8df5\u7684\u306a\u4f8b\u3068\u30b3\u30fc\u30c9\u3001\u6ce8\u610f\u70b9\u3092\u542b\u3081\u3066\u521d\u5fc3\u8005\u306b\u3082\u7406\u89e3\u3067\u304d\u308b\u3088\u3046\u8aac\u660e\u3057\u307e\u3059\u3002","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.silicloud.com\/ja\/blog\/java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306e\u4f8b\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb\/","og_locale":"ja_JP","og_type":"article","og_title":"Java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306e\u4f8b\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb","og_description":"Java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306e\u4f8b\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb\u3092\u5206\u304b\u308a\u3084\u3059\u304f\u89e3\u8aac\u3002\u5b9f\u8df5\u7684\u306a\u4f8b\u3068\u30b3\u30fc\u30c9\u3001\u6ce8\u610f\u70b9\u3092\u542b\u3081\u3066\u521d\u5fc3\u8005\u306b\u3082\u7406\u89e3\u3067\u304d\u308b\u3088\u3046\u8aac\u660e\u3057\u307e\u3059\u3002","og_url":"https:\/\/www.silicloud.com\/ja\/blog\/java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306e\u4f8b\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb\/","og_site_name":"Blog - Silicon Cloud","article_published_time":"2023-09-11T18:17:59+00:00","article_modified_time":"2025-07-31T16:24:33+00:00","author":"\u590f\u6a39, \u98a8","twitter_card":"summary_large_image","twitter_misc":{"\u57f7\u7b46\u8005":"\u590f\u6a39, \u98a8","\u63a8\u5b9a\u8aad\u307f\u53d6\u308a\u6642\u9593":"42\u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%ae%e3%83%aa%e3%83%95%e3%83%ac%e3%82%af%e3%82%b7%e3%83%a7%e3%83%b3%e3%81%ae%e4%be%8b%e3%81%ae%e3%83%81%e3%83%a5%e3%83%bc%e3%83%88%e3%83%aa%e3%82%a2%e3%83%ab\/","url":"https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%ae%e3%83%aa%e3%83%95%e3%83%ac%e3%82%af%e3%82%b7%e3%83%a7%e3%83%b3%e3%81%ae%e4%be%8b%e3%81%ae%e3%83%81%e3%83%a5%e3%83%bc%e3%83%88%e3%83%aa%e3%82%a2%e3%83%ab\/","name":"Java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306e\u4f8b\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb - Blog - Silicon Cloud","isPartOf":{"@id":"https:\/\/www.silicloud.com\/ja\/blog\/#website"},"datePublished":"2023-09-11T18:17:59+00:00","dateModified":"2025-07-31T16:24:33+00:00","author":{"@id":"https:\/\/www.silicloud.com\/ja\/blog\/#\/schema\/person\/4e591db2661c4cc425470b461259391d"},"description":"Java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306e\u4f8b\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb\u3092\u5206\u304b\u308a\u3084\u3059\u304f\u89e3\u8aac\u3002\u5b9f\u8df5\u7684\u306a\u4f8b\u3068\u30b3\u30fc\u30c9\u3001\u6ce8\u610f\u70b9\u3092\u542b\u3081\u3066\u521d\u5fc3\u8005\u306b\u3082\u7406\u89e3\u3067\u304d\u308b\u3088\u3046\u8aac\u660e\u3057\u307e\u3059\u3002","breadcrumb":{"@id":"https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%ae%e3%83%aa%e3%83%95%e3%83%ac%e3%82%af%e3%82%b7%e3%83%a7%e3%83%b3%e3%81%ae%e4%be%8b%e3%81%ae%e3%83%81%e3%83%a5%e3%83%bc%e3%83%88%e3%83%aa%e3%82%a2%e3%83%ab\/#breadcrumb"},"inLanguage":"ja","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%ae%e3%83%aa%e3%83%95%e3%83%ac%e3%82%af%e3%82%b7%e3%83%a7%e3%83%b3%e3%81%ae%e4%be%8b%e3%81%ae%e3%83%81%e3%83%a5%e3%83%bc%e3%83%88%e3%83%aa%e3%82%a2%e3%83%ab\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%ae%e3%83%aa%e3%83%95%e3%83%ac%e3%82%af%e3%82%b7%e3%83%a7%e3%83%b3%e3%81%ae%e4%be%8b%e3%81%ae%e3%83%81%e3%83%a5%e3%83%bc%e3%83%88%e3%83%aa%e3%82%a2%e3%83%ab\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/www.silicloud.com\/ja\/blog\/"},{"@type":"ListItem","position":2,"name":"Java\u306e\u30ea\u30d5\u30ec\u30af\u30b7\u30e7\u30f3\u306e\u4f8b\u306e\u30c1\u30e5\u30fc\u30c8\u30ea\u30a2\u30eb"}]},{"@type":"WebSite","@id":"https:\/\/www.silicloud.com\/ja\/blog\/#website","url":"https:\/\/www.silicloud.com\/ja\/blog\/","name":"Blog - Silicon Cloud","description":"","inLanguage":"ja"},{"@type":"Person","@id":"https:\/\/www.silicloud.com\/ja\/blog\/#\/schema\/person\/4e591db2661c4cc425470b461259391d","name":"\u590f\u6a39, \u98a8","image":{"@type":"ImageObject","inLanguage":"ja","@id":"https:\/\/www.silicloud.com\/ja\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/65e0ff40534461b1fa000382dc194e1716f793ab0bcb218ac3c40895551a08c5?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/65e0ff40534461b1fa000382dc194e1716f793ab0bcb218ac3c40895551a08c5?s=96&d=mm&r=g","caption":"\u590f\u6a39, \u98a8"},"url":"https:\/\/www.silicloud.com\/ja\/blog\/author\/natsukikaze\/"},{"@type":"ImageObject","inLanguage":"ja","@id":"https:\/\/www.silicloud.com\/ja\/blog\/java%e3%81%ae%e3%83%aa%e3%83%95%e3%83%ac%e3%82%af%e3%82%b7%e3%83%a7%e3%83%b3%e3%81%ae%e4%be%8b%e3%81%ae%e3%83%81%e3%83%a5%e3%83%bc%e3%83%88%e3%83%aa%e3%82%a2%e3%83%ab\/#local-main-organization-logo","url":"","contentUrl":"","caption":"Blog - Silicon Cloud"}]}},"_links":{"self":[{"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/posts\/654","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/users\/9"}],"replies":[{"embeddable":true,"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/comments?post=654"}],"version-history":[{"count":1,"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/posts\/654\/revisions"}],"predecessor-version":[{"id":43337,"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/posts\/654\/revisions\/43337"}],"wp:attachment":[{"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/media?parent=654"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/categories?post=654"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.silicloud.com\/ja\/blog\/wp-json\/wp\/v2\/tags?post=654"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}