å®éãJavaã«ã¯1.1ã®æ代ããï¼ã¤ã³ãã¼ã¯ã©ã¹ã¨ããå½¢ã§ï¼ã¯ãã¼ã¸ã£ãããã¾ãã次ã®ã³ã¼ããè¦ã¦ä¸ããã public interface IFilter { public boolean filter(int x); } public class FilterFactory { public static IFilter greaterThan(final int i) { return new IFilter() { public boolean filter(int x) { // iã¯èªå½çã¹ã³ã¼ãã®å¤é¨ããä¸ãããã return x > i; } }; } } ä¸è¨ã®ã³ã¼ããµã³ãã«ã§ã¯ãFilterFactoryã«greaterThanã¨ãããã¡ã¯ããªã¡ã½ããããããããã¯å¼ã³åºãã«éãã¦å¼æ°ã«é¢ããã¯ãã¼ã¸ã£ãè¿ãã¾ããåãã³ã¼ããç°ãªãå¼æ°ã§å¼ã³åºãã¨ãç°ãªãã¯ãã¼ã¸ã£
{{#tags}}- {{label}}
{{/tags}}