Flutter: Filter list as per some condition

后端 未结 3 1315
感动是毒
感动是毒 2020-12-13 07:56

I\'m having list of Movies. That contains all Animated & non Animated Movies. To identify whether its Animated or not there is one flag called as isAnimated

3条回答
  •  孤城傲影
    2020-12-13 08:48

    toList() is missing to materializer the result

    _AnimatedMovies = AllMovies.where((i) => i.isAnimated).toList();
    

提交回复
热议问题