ã¤ã³ã¿ãã§ã¼ã¹ã§é¨ååå¾¹åº ã«ããã¦ãã¤ã³ã¿ãã§ã¼ã¹ã¯ã¤ã³ã¹ã¿ã³ã¹ãä½ããã¨ãã§ããªãã¨æ¸ãã¾ããããç¡åã¯ã©ã¹ã使ãã¨ãã¤ã³ã¿ãã§ã¼ã¹ãã¤ã³ã¹ã¿ã³ã¹åããããã®ãããªã³ã¼ãã«ãªãã¾ãã package kihon; public class Sample { public static void main( String args[] ) { Cafe cafe=new Cafe(){ public void welcome(){ System.out.println("ããã£ãããã¾ã"); } }; cafe.welcome(); } } interface Cafe{ public void welcome(); } å®è¡çµæ :ããã£ãããã¾ãã ä¸ã®ä¾ã®å ´åãæ¬æ¥ã§ããã°ãCafeã¤ã³ã¿ãã§ã¼ã¹ãå®è£ ããã¯ã©ã¹ãå®ç¾©ãã¦ããã®ã¯ã©ã¹ã®ã¤ã³ã¹ã¿ã³ã¹ãä½ã£ã¦ã¡ã½ãããå®è¡ããã®ãç
{{#tags}}- {{label}}
{{/tags}}