Last active
October 11, 2015 12:17
-
-
Save aruld/3857601 to your computer and use it in GitHub Desktop.
MyList usage with exists() API
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Run with -Xbootclasspath/p:target/classes as ReferencePipeline access is now package local, so use this trick | |
List<Tweet> googleTweets3 = tweets.stream().filter(tweet -> (new MyList<>(google).stream().exists(tweet.text::contains))).collect(toList()); | |
List<Tweet> appleTweets3 = tweets.stream().filter(tweet -> (new MyList<>(apple).stream().exists(tweet.text::contains))).collect(toList()); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment