Combiner & BiFunction (original) (raw)
Remi Forax forax at univ-mlv.fr
Sat Dec 8 08:30:32 PST 2012
- Previous message: Combiner & BiFunction
- Next message: Combiner & BiFunction
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On 12/08/2012 04:52 PM, Brian Goetz wrote:
Yes, its on my list to rationalize these.
Can you also normalize the Function and Operator types name ?
when it was Mapper instead of Function, it was not a big deal, but now with the name Function, Operator and Function names are not aligned.
Function -> UnaryOperator BiFunction -> BinaryOperator
also the experience of other language show that sometime user will want to create a function with 5 arguments, we will obviously not add TriFunction, QuadriFunction, QuintiFunction, etc. in the jdk, I think that using a latin prefix to indicate the arity is not the best convention, other languages tend to use Function, Function2, Function3 and so on.
so I propose Function -> Operator Function2 -> Operator2 with the convention that if there is no number the arity is 1.
also using a suffix is better because the primitive specialization use a prefix (avoid the question, is it IntBiFunction or BiIntFunction ?)
regards, Rémi
On 12/8/2012 10:45 AM, Remi Forax wrote: I've just found that we have the very same functional interface twice, Combiner and BiFunction.
Rémi
- Previous message: Combiner & BiFunction
- Next message: Combiner & BiFunction
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the lambda-libs-spec-experts mailing list