One more pass on flatMap/mapMulti (original) (raw)

Tim Peierls tim at peierls.net
Thu Jan 10 09:41:00 PST 2013


Any of those three are an improvement, and extending Block seems reasonable. (Though I still hesitate every time I see "Block" or "BiBlock" -- the latter looks like "bib lock", something you would use to prevent an infant from removing protective clothing.)

On Thu, Jan 10, 2013 at 12:35 PM, Brian Goetz <brian.goetz at oracle.com>wrote:

I like the idea that whatever is passed to the block describes the downstream; the role of the block is to emit values downstream. I think that makes things clearer about what's going on, which is good because what is going on is already not all that clear.

I buy that "Downstream" could use some nounification. (Calvin say: verbing weirds language.) DownstreamCollector DownstreamAcceptor DownstreamHandler accept() is OK, and we can make it extend Block.

On 1/10/2013 12:28 PM, Tim Peierls wrote: On Thu, Jan 10, 2013 at 11:59 AM, Brian Goetz <brian.goetz at oracle.com_ _<mailto:brian.goetz at oracle.com**>> wrote:

Bikeshed discussions can continue.

OK, then! :-) The method name "send" is OK, but you wouldn't be seeing it in the signature of explode. What you would see is Downstream, which still bugs me. The word "downstream" is an adverb or adjective, not a noun. Things are sent downstream, they aren't sent to a downstream. Was Acceptor.accept proposed and rejected already? If so, why? I would understand explode(BiBlock<Acceptor, T>))_ --tim



More information about the lambda-libs-spec-observers mailing list