Method references with types [Re: lambda syntax tutorial]
John Nilsson
john at milsson.nu
Fri Aug 6 19:52:10 PDT 2010
Completness I guess. If a short hand for method calling wrappers is
provided. The shorthand should also allow method chaining and if
method chaining is support, why not arbitrary expressions?
Again, I'm thinking about the use case of declaring property lists to
extract from a collection.
I want to replace this
printAsCsv(customerList,"customerNo","name.first","name.last", "age");
with something type-safe, still easy to to read and hopefully not add
any boilerplate.
BR,
John
On Fri, Aug 6, 2010 at 4:17 AM, Brian Goetz <brian.goetz at oracle.com> wrote:
> Why?
>
> On 8/5/2010 9:54 PM, John Nilsson wrote:
>>
>> On Fri, Aug 6, 2010 at 12:59 AM, Stephen Colebourne
>> <scolebourne at joda.org> wrote:
>>>
>>> The complete set of conversions would be:
>>> [...]
>>
>> How about expressions?
>>
>> #String.length() + 2
>>
>> #A.getB().getC()
>>
>> and even partiall application?
>>
>> #A.getB(2).getC()
>>
>> #A.getB(Integer).getC()
>>
>> BR,
>> John
>>
>
More information about the lambda-dev
mailing list