on 05-21-2016 4:17 AM
HI I am using groovy script to generate some report and in my groovy script I have to use multiple method. Is it possible to write groovy for that.If yes what will be the syntax for that ? Thanks in advance, Amit
Hi Amit,
If you want to use beanshell,you can follow below syntax.
//import statement..
String getName(List list){ String str = "JHON"; return str; }
System.out.println(getName(new ArrayList()));
Regards,
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You can create groovy methods in the script:
// groovy script
//call myMethod
myMethod()
def myMethod() {
// method does something
}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
2 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.