ä»åã¯Stream#collectã®å é¨æ§é ã®æ¦è¦ãç´¹ä»ããã 以åã®è¨äºã§ã¯ãStreamã§å å·¥ãããã¼ã¿ãListçã®ãã¼ã¿æ§é ã«å¤æããéã«collect(Collectors.toList())ã®ãããªã³ã¼ããæ¸ããã ãããStream#collectã¯Stream APIã®æ±ç¨çãªçµç«¯æä½ã§ãããããListã ãã§ãªãæ§ã ãªãã¼ã¿æ§é ã¸ã®å¤æãå¯è½ã§ããã å¯å¤ãªãã¯ã·ã§ã³æä½ã¨ã¯ Stream#collect ããã³ãä»å解説ããCollectorã®Javadocã«ã¯ããå¯å¤ãªãã¯ã·ã§ã³æä½ï¼mutable reduction operationï¼ãã¨ããè¨èãç»å ´ããã®ã§ãããã§ç°¡åã«èª¬æãã¦ããã ããªãã¯ã·ã§ã³æä½ãã¨ã¯ãä¸é£ã®è¦ç´ ã«ç¹å®ã®æ¼ç®ãé©ç¨ãã¦1ã¤ã«ã¾ã¨ããæä½ã§ããã ãã¨ãã°ãæ°å¤ã®ãªã¹ãã®åè¨å¤ãæ±ããå¦çã¯ãæ°å¤ãªã¹ãã«è¦ç´ å士ã®å ç®ã¨ããæ¼ç®ãé©ç¨ã
{{#tags}}- {{label}}
{{/tags}}