{"id":3344,"date":"2014-08-05T05:24:31","date_gmt":"2014-08-04T20:24:31","guid":{"rendered":"http:\/\/fry.no.coocan.jp\/WordPress\/?p=3344"},"modified":"2014-08-05T19:06:42","modified_gmt":"2014-08-05T10:06:42","slug":"%e5%b7%a5%e4%ba%8b%e8%a6%8b%e7%a9%8d%e3%82%82%e3%82%8a","status":"publish","type":"post","link":"http:\/\/fry.no.coocan.jp\/WordPress\/?p=3344","title":{"rendered":"\u5de5\u4e8b\u898b\u7a4d\u3082\u308a"},"content":{"rendered":"<p>\u30de\u30f3\u30b7\u30e7\u30f3\u306e\u5927\u898f\u6a21\u6539\u4fee\u5de5\u4e8b\u306e\u898b\u7a4d\u3082\u308a\u3092\uff18\u793e\u304b\u3089\u3068\u3063\u305f\u3068\u3053\u308d\u3001\u540c\u984d\u306e\u898b\u7a4d\u3082\u308a\u3092\u51fa\u3057\u3066\u304d\u305f\u4f1a\u793e\u304c\uff12\u7d44\u3042\u308a\u307e\u3057\u305f\u3002<br \/>\n\uff21\u793e\u3001\uff22\u793e\u304c2nm,000,000\u5186<br \/>\n\uff23\u793e\u3001\uff24\u793e\u304c2ab,cd0,000\u5186<br \/>\n\uff12\u5104\u5186\u898f\u6a21\u306e\u8a71\u3067\u3001\uff11\u4e07\u5186\u306e\u4f4d\u307e\u3067\u540c\u3058\u3068\u3044\u3046\u306e\u306f\u4e0d\u81ea\u7136\u3067\u3059\u3088\u306d\u3002<\/p>\n<p>(1)\u4e0b\u8acb\u3051\u304c\u540c\u3058\u306a\u306e\u304b\uff1f(2)\u8ac7\u5408\u304b\uff1f(3)\u898b\u7a4d\u3082\u308a\u4f1a\u793e\u304c\u3042\u3063\u3066\u305d\u3053\u306b\u5916\u6ce8\u3057\u3066\u3044\u308b\u306e\u304b\uff1f\u306a\u3093\u3066\u7591\u3063\u3066\u3057\u307e\u3044\u307e\u3059\u3002<\/p>\n<p>\uff1d\uff1d\uff1d<br \/>\n\u4eca\u65e5\u306f\u3001\u663c\u304b\u3089\u30b7\u30e7\u30fc\u30c8\u30c6\u30cb\u30b9\u3092\u4e88\u5b9a\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\uff08\u500b\u4eba\u7684\u8208\u5473\u3067\uff09\u795e\u7d4c\u306e\u52c9\u5f37\u3092\u59cb\u3081\u3066\u3044\u307e\u3059\u304c\u3001\u4e00\u5411\u306b\u982d\u306b\u5165\u3063\u3066\u304d\u307e\u305b\u3093\u3002\u751f\u7269\u7cfb\u306f\u5411\u3044\u3066\u306a\u3044\u3093\u3067\u3059\u304b\u306d\uff1f<\/p>\n<p>\u4eca\u65e5\u3082\u5bcc\u58eb\u5c71\u304c\u898b\u3048\u307e\u3059\u3002<br \/>\n<a href=\"http:\/\/fry.no.coocan.jp\/WordPress\/wp-content\/uploads\/2014\/08\/2f70466fc3e77d55f0ca29b565144e70.jpg\"><img loading=\"lazy\" class=\"alignnone size-full wp-image-3347\" title=\"\uff46\" src=\"http:\/\/fry.no.coocan.jp\/WordPress\/wp-content\/uploads\/2014\/08\/2f70466fc3e77d55f0ca29b565144e70.jpg\" alt=\"\" width=\"320\" height=\"180\" srcset=\"http:\/\/fry.no.coocan.jp\/WordPress\/wp-content\/uploads\/2014\/08\/2f70466fc3e77d55f0ca29b565144e70.jpg 320w, http:\/\/fry.no.coocan.jp\/WordPress\/wp-content\/uploads\/2014\/08\/2f70466fc3e77d55f0ca29b565144e70-300x168.jpg 300w\" sizes=\"(max-width: 320px) 100vw, 320px\" \/><\/a><\/p>\n<p>\uff1d\uff1d\uff1d<br \/>\n\u30d7\u30ed\u30b0\u30e9\u30e0\u4f5c\u6210\u306e\u969b\u306e\u30e1\u30e2\u3067\u3059\u3002<br \/>\n\u6574\u6570buff\u3092\u3001\uff12\u3064\u306e\u30af\u30e9\u30b9\uff08A\u3068B\uff09\u3067\u5171\u6709\u3059\u308b\u65b9\u6cd5\u3002<\/p>\n<p>\uff08\uff11\uff09\u6700\u3082\u30b7\u30f3\u30d7\u30eb\u306a\u65b9\u6cd5<br \/>\npublic class Share5{<\/p>\n<p>public static void main(String[] args) {<br \/>\nint buff=0;<br \/>\nA a= new A();<br \/>\na.put(1);<br \/>\nSystem.out.println(a.get());<br \/>\nB b= new B();<br \/>\nSystem.out.println(b.get());<br \/>\n}<br \/>\n}<\/p>\n<p>class\u00a0 A {<\/p>\n<p>public int get(){<br \/>\nreturn buff<br \/>\n}<\/p>\n<p>public void put(int i){<br \/>\nbuff=i;<br \/>\n}<\/p>\n<p>}<\/p>\n<p>class B {<\/p>\n<p>public int get(){<br \/>\nreturn buff;<br \/>\n}<\/p>\n<p>public void put(int i){<br \/>\nbuff=i;<br \/>\n}<br \/>\n}<\/p>\n<p>\uff08\uff12\uff09\u30af\u30e9\u30b9\u5909\u6570\u3092\u4f7f\u3046\u65b9\u6cd5<br \/>\npublic class Share4{<\/p>\n<p>static int buff=0;<\/p>\n<p>public static void main(String[] args) {<\/p>\n<p>A a= new A();<br \/>\na.put(1);<br \/>\nSystem.out.println(a.get());<br \/>\nB b= new B();<br \/>\nSystem.out.println(b.get());<br \/>\n}<br \/>\n}<\/p>\n<p>class\u00a0 A {<\/p>\n<p>public int get(){<br \/>\nreturn Share4.buff;<br \/>\n}<\/p>\n<p>public void put(int i){<br \/>\nShare4.buff=i;<br \/>\n}<\/p>\n<p>}<\/p>\n<p>class B {<\/p>\n<p>public int get(){<br \/>\nreturn Share4.buff;<br \/>\n}<\/p>\n<p>public void put(int i){<br \/>\nShare4.buff=i;<br \/>\n}<br \/>\n}<br \/>\n\uff08\uff13\uff09buff\u304c\u30af\u30e9\u30b9\uff08\uff33\uff09\u5185\u306b\u3042\u308b\u5834\u5408<br \/>\npublic class Share2{<\/p>\n<p>public static void main(String[] args) {<br \/>\nS s= new S();<br \/>\nA a= new A(s);<br \/>\na.put(1);<br \/>\nSystem.out.println(a.get());<br \/>\nB b= new B(s);<br \/>\nSystem.out.println(b.get());<br \/>\n}<br \/>\n}<\/p>\n<p>class S{<br \/>\nint buff=0;<\/p>\n<p>public int get(){<br \/>\nreturn buff;<br \/>\n}<\/p>\n<p>public void put(int i){<br \/>\nbuff=i;<br \/>\n}<br \/>\n}<\/p>\n<p>class\u00a0 A {<br \/>\nS s;<\/p>\n<p>public\u00a0\u00a0 A(S s){<br \/>\nthis.s=s;<br \/>\n}<\/p>\n<p>public int get(){<br \/>\nreturn s.get();<br \/>\n}<\/p>\n<p>public void put(int i){<br \/>\ns.put(i);<br \/>\n}<\/p>\n<p>}<\/p>\n<p>class B {<br \/>\nS s;<\/p>\n<p>public B(S s){<br \/>\nthis.s= s;<br \/>\n}<\/p>\n<p>public int get(){<br \/>\nreturn s.get();<br \/>\n}<\/p>\n<p>public void put(int i){<br \/>\ns.put(i);<br \/>\n}<br \/>\n}<\/p>\n<p>\uff08\uff14\uff09buff\u304c\u30af\u30e9\u30b9\uff08\uff33\uff09\u5185\u306b\u3042\u308b\u5834\u5408\u3001\u7d99\u627fextends\u3092\u4f7f\u3046\u65b9\u6cd5<br \/>\npublic class Share3{<\/p>\n<p>public static void main(String[] args) {<br \/>\nA a= new A();<br \/>\na.put(1);<br \/>\nSystem.out.println(a.get());<br \/>\nB b= new B();<br \/>\nSystem.out.println(b.get());<br \/>\n}<br \/>\n}<\/p>\n<p>class S{<br \/>\nstatic int buff=0;<\/p>\n<p>public int get(){<br \/>\nreturn buff;<br \/>\n}<\/p>\n<p>public void put(int i){<br \/>\nbuff=i;<br \/>\n}<br \/>\n}<\/p>\n<p>class\u00a0 A extends S{<\/p>\n<p>}<\/p>\n<p>class B extends S{<\/p>\n<p>}<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u30de\u30f3\u30b7\u30e7\u30f3\u306e\u5927\u898f\u6a21\u6539\u4fee\u5de5\u4e8b\u306e\u898b\u7a4d\u3082\u308a\u3092\uff18\u793e\u304b\u3089\u3068\u3063\u305f\u3068\u3053\u308d\u3001\u540c\u984d\u306e\u898b\u7a4d\u3082\u308a\u3092\u51fa\u3057\u3066\u304d\u305f\u4f1a\u793e\u304c\uff12\u7d44\u3042\u308a\u307e\u3057\u305f\u3002 \uff21\u793e\u3001\uff22\u793e\u304c2nm,000,000\u5186 \uff23\u793e\u3001\uff24\u793e\u304c2ab,cd0,000\u5186 \uff12\u5104\u5186\u898f\u6a21\u306e\u8a71\u3067\u3001\uff11\u4e07\u5186\u306e\u4f4d\u307e\u3067\u540c &hellip; <a href=\"http:\/\/fry.no.coocan.jp\/WordPress\/?p=3344\">\u7d9a\u304d\u3092\u8aad\u3080 <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[1],"tags":[],"_links":{"self":[{"href":"http:\/\/fry.no.coocan.jp\/WordPress\/index.php?rest_route=\/wp\/v2\/posts\/3344"}],"collection":[{"href":"http:\/\/fry.no.coocan.jp\/WordPress\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/fry.no.coocan.jp\/WordPress\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/fry.no.coocan.jp\/WordPress\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/fry.no.coocan.jp\/WordPress\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=3344"}],"version-history":[{"count":3,"href":"http:\/\/fry.no.coocan.jp\/WordPress\/index.php?rest_route=\/wp\/v2\/posts\/3344\/revisions"}],"predecessor-version":[{"id":3346,"href":"http:\/\/fry.no.coocan.jp\/WordPress\/index.php?rest_route=\/wp\/v2\/posts\/3344\/revisions\/3346"}],"wp:attachment":[{"href":"http:\/\/fry.no.coocan.jp\/WordPress\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=3344"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/fry.no.coocan.jp\/WordPress\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=3344"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/fry.no.coocan.jp\/WordPress\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=3344"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}