Java印申请 我需要能够让用户拯救物体的状况。 这需要节省以前通过全球倡议或通过全球倡议创造的一套习惯功能,并在晚些时候装载这些储存的功能。 基本上,我需要编辑和编辑职能。
现在,我通过使用功能标语......toString(......)方法实现序列化:
func.toString().replace( " , " ).replace(/(
)/g, ).replace(/(
)/g, ).replace(/( )/g, )
这使我具有像这一美丽的“航空”职能(指出职能没有名称):
"function (someParameter) {this.someFunctionName(return something ;}"
这是我斗争的领域。 我目前最妥善的办法,就是使各项职能民主化:
var func = eval( t = + so.actions[i].func);
Note how I prepend the serialized function with t =
before calling eval()
on it. I don t like doing this because it creates a global variable but I cannot find a way around it. When not prepending this, I receive a "SyntaxError: Unexpected token (". When prepending var t =
, eval() does not return the function but undefined
.
是否有替代的“统一”功能?
PS:我知道在用户投入上使用电子数据对安全的影响。 在可预见的未来,我是唯一使用这一软件的人,因此,目前这是一个非问题。