The Altair Community is migrating to a new platform to provide a better experience for you. In preparation for the migration, the Altair Community is on read-only mode from October 28 - November 6, 2024. Technical support via cases will continue to work as is. For any urgent requests from Students/Faculty members, please submit the form linked here
Scripting and Multiple Input/Output [SOLVED]
Hi, guys,
New guy here. I'm writing a script in Groovy using the Execute Script operator and I'm having some issues with the inputs. I know that it is easy to retrieve the first input (operator.getInput(SomeClass.class)). But if I have multiple inputs, how would I access the second/third/nth?
And for outputs, is there an operator.setOutput or similar function? Because of course you can only return one value from a Java/Groovy function.
Thanks!
New guy here. I'm writing a script in Groovy using the Execute Script operator and I'm having some issues with the inputs. I know that it is easy to retrieve the first input (operator.getInput(SomeClass.class)). But if I have multiple inputs, how would I access the second/third/nth?
And for outputs, is there an operator.setOutput or similar function? Because of course you can only return one value from a Java/Groovy function.
Thanks!
0
Answers
access inputs via to return multiple outputs, see my second answer below.
Regards,
Marco
Thanks so much for your help! The input works great but I'm having some trouble with the output. I am getting a warning The rest of the warning goes on to describe the example sets in the container, which are correct. However, none of the operators to which I connect the output ports are receiving any data. Thoughts?
Thanks again.
sorry my bad. You can simply do the following: Regards,
Marco