119.8. 複数のステートメントスクリプトからの結果を取得する方法
Camel 2.14 から利用可能
scripteengine evale メソッドは、複数の統計スクリプトを実行すると Null を返します。Camel は、値セットから「result」のキーを使用してスクリプト結果の値を検索するようになりました。複数のステートメントスクリプトがある場合は、結果変数の値をスクリプトの戻り値として設定する必要があります。
bar = "baz";
# some other statements ...
# camel take the result value as the script evaluation result
result = body * 2 + 1