如何在Beanshell中使用或转义Java 8 Lambda表达式 [英] How to use or escape java 8 Lambda expressions in Beanshell

查看:220
本文介绍了如何在Beanshell中使用或转义Java 8 Lambda表达式的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在研究使用Beanshell env进行产品自定义挂钩的产品(在Tomcat中运行的Sailpoint IdentityIQ).我想编写一些代码来解析大型csv文件,并希望利用Java 8 Streams.但是我面对Beanshell env引发错误的问题,尽管我们使用的是Java 8,但无法识别Lambda表达式

I'm working on a Product (Sailpoint IdentityIQ that runs in Tomcat) which uses Beanshell env for product customization hooks. I want to write some code to parse a large csv file and want to leverage Java 8 Streams. But I'm facing issue with Beanshell env throwing errors and didn't recognize the Lambda expressions though we are using Java 8

有什么方法可以告诉beanshell识别lambda或在代码中转义

Is there any way we can tell beanshell to recognize the lambdas or escape in the code

推荐答案

Lambda表达式仍不支持在豆壳中

Lambda expressions still not supported in beanshell

Lambda即将到来,请放心!有了使用方法句柄的新方法,我们就可以利用Lambda Meta Factory创建函数对象,只有一步之遥,除非我们不能简单地走与Java EL相同的路线……我们有选择.

Lambdas are coming, rest assured! With the new approach of using Method Handles we are one step closer to utilise Lambda Meta Factory for creating function objects, unless we don't simply go the same route as with Java EL... we have options.

这篇关于如何在Beanshell中使用或转义Java 8 Lambda表达式的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆