I intend to create a perspective component which contains some text fields as the input and there will be a function in the gateway scope which accepts these input from the perspective component as params to run its application.
I looked at the examples of gateway scope and perspective component from the github examples.
The former example uses maven build while the later seems to be using gradle build tool.
I am not familiar with gradle build tool. Is there any way to build the perspective component using Maven build?
If so could you help me with an example?
Thanks for the information.
Well, just another query, As i have mentioned above, the perspective component will pass the inputs as parameters to a gateway scope function and it is a single module functionality, is it that even the gateway scope should be built using gradle? i mean, should all the scopes present with the perspective component should be using gradle only?
Put directly, I'm not sure you understand what's happening well enough to even ask the right questions.
How you bundle your dependencies and code is entirely irrelevant to Ignition. We provide Maven and Gradle module plugins to make things easier, but they're not required.
If you want to make a scripting function (I can't really tell what you mean by "a function in the gateway scope" besides a scripting function), it's extremely easy to simply copy the code in the scripting function example into the Perspective example. A module's gateway hook can do any number of things; it's not like there's any restriction that says a module must only do one or the other thing. We even have a Gradle-ified example of the scripting function available in a different repo: ignition-sdk-training/scripting-function-g at main · inductiveautomation/ignition-sdk-training · GitHub
All that said, you probably don't actually need a scripting function at all? If you want your Perspective component to be able to run some arbitrary Java code on demand, you can already do that - the component model for Perspective supports arbitrary 'Delegate' registration, such that we will create an instance of a Java class for you, in sync with the component lifecycle on the frontend, and expose whatever script callable methods you want, or add component message hooks that your frontend code can fire.
I can speak from experience, it is about 1,000,000,000 times easier to use the existing Gradle libraries than trying to convert over to using maven. I spent weeks of time in the process of converting it over to using maven but it was a headache. It was much easier to use the Gradle version.