greptilian logo

IRC log for #friendlyjava, 2016-01-30

##friendlyjava on freenode

| Channels | #friendlyjava index | Today | | Search | Google Search | Plain-Text | plain, newest first | summary

All times shown according to UTC.

Time S Nick Message
00:56 sfisque1 joined ##friendlyjava
03:26 mr_lou joined ##friendlyjava
06:25 bluezone joined ##friendlyjava
11:01 pdurbin_m joined ##friendlyjava
11:01 pdurbin_m Java EE Management API 2.0 (JSR 373) Spins Up (The Aquarium): https://blogs.oracle.com/theaquarium/entry/java_ee_management_api_2
12:44 philbot joined ##friendlyjava
12:44 Topic for ##friendlyjava is now Be friendly :) This channel is publicly logged at http://irclog.greptilian.com/friendlyjava/today
12:44 searchbot joined ##friendlyjava
13:00 pdurbin joined ##friendlyjava
14:20 saggoy joined ##friendlyjava
14:24 aditsu_ joined ##friendlyjava
14:25 aditsu_ hai, can haz java 8? :)
14:26 saggoy left ##friendlyjava
14:26 aditsu_ basically I want to write some code that produces some values, and use a Consumer (or whatever) to separate the processing part
14:27 aditsu_ one possible use is to collect them into a List
14:28 aditsu_ java 8 has Consumer and Collectors.toList, but they seem to be unrelated
14:28 aditsu_ how can I use a Collector as a Consumer? or is there a Consumer that just puts things into a List?
14:34 pdurbin aditsu_: you're starting to play with Java 8?
14:34 aditsu_ I started a few months ago, but haven't done a lot
14:37 pdurbin the main thing I've done is work through these exercises (which I recommend): https://github.com/stuart-marks/LambdaHOLv2
14:38 aditsu__ joined ##friendlyjava
14:39 aditsu__ sorry, disconnected
14:39 aditsu__ you probably know I've been fiddling with javafx
14:39 pdurbin aditsu_: did you see the github repo I linked?
14:39 aditsu_ I see it now in the logs
14:40 aditsu_ bah, github :p
14:41 aditsu_ anyway, I'll check it out, but do you have any tips about my question?
14:43 pdurbin aditsu_: there's a lot of .collect(toList()) at https://github.com/stuart-marks/LambdaHOLv2/blob/master/LambdaLab/test/solutions/Exercises.java
14:44 pdurbin not sure if that helps
14:44 aditsu_ pdurbin: I know how to collect a stream, but I don't have a stream here
14:46 aditsu_ I would like to use a Consumer
14:47 pdurbin hmm, well there's some IntConsumer in there
14:48 aditsu_ oh, I think it's actually easy to just write it
14:49 aditsu_ that is, a Consumer that collects to a List
14:49 pdurbin aditsu_: you'll have to paste some code for us once you figure it out
14:49 aditsu_ final List<Integer> l = new ArrayList<>();
14:49 aditsu_ final Consumer<Integer> c = l::add;
14:49 aditsu_ I just tried that kinda randomly, and it actually worked :o
14:50 pdurbin heh
14:50 aditsu_ I use it like: c.accept(3);
14:52 pdurbin we *just* switched to Java 8 in out last release. I should start playing with the new goodies
14:53 pdurbin I've had this book since JavaOne 2014 (signed by the author!) and it seems good: https://github.com/java8/Java8InAction
14:54 aditsu_ huh, IntConsumer is not a Consumer, but a similar class that accepts the primitive type int rather than Integer
14:54 aditsu_ that seems to be a pattern in java 8 - they write separate classes/methods for different primitive types
14:55 pdurbin definitely some consumer stuff in that book: https://github.com/java8/Java8InAction/search?utf8=%E2%9C%93&q=consumer
14:57 aditsu_ I think they really went overboard with a lot of this stuff... but hey, it's java :p
14:57 aditsu_ bbl
14:58 pdurbin Is anyone here doing any Android development?
15:16 aditsu I'm not actively doing it, but have some interest (and almost no experience)
15:17 pdurbin I worked on https://github.com/IQSS/dataverse-android a year ago and haven't touched it since.
15:17 pdurbin but my question is more about another app
15:18 pdurbin one that I actually use: https://github.com/AntennaPod/AntennaPod
15:20 saggoy joined ##friendlyjava
15:21 saggoy left ##friendlyjava
15:26 aditsu haha, podcasts, github and mobile, that's so pdurbin :)
15:29 pdurbin :)
15:54 aditsu_ joined ##friendlyjava
16:48 sfisque1 pdurbin i am actually about to try a little dabble in android
16:49 sfisque i did do a very trivial port of my old j2me palm app, but that was mostly a toy app.  basically uses the local web services cross indexed with gps to find nearby bus/rail stops and tell you next arrivals
16:51 sfisque i'm considering a mathy type game for my kids to play, this time around, something like a flash card game, simple with funny fx to engage them
18:20 pdurbin sfisque: cool. My kids love this math game: https://www.prodigygame.com
20:53 bluezone joined ##friendlyjava
23:55 nanoz joined ##friendlyjava

| Channels | #friendlyjava index | Today | | Search | Google Search | Plain-Text | plain, newest first | summary

##friendlyjava on freenode