阅读背景:

Java8 的 Stream 快速实现List转map 、分组、过滤等操作_njq960920的博客

来源:互联网 

利用java8新特性,可以用简洁高效的代码来实现一些数据处理。

定义一个对象

public class Apple {
    private Integer id;
    private String name;
    private BigDecimal money;
    private Integer num;
    public Apple(Integer id, String name, BigDecimal money, Integer num) {
        this.id = id;
        this.name = name;
        this.money = money;
        this.num = num;
    }
}publ



你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: