Does custom keyword support recursion?

Hi,

i wrote a method in the keyword section.
my method uses recursion i.e. calls itself.
but i’m getting an error every time:
[ERROR] - No such property: CustomKeywords for class: utilities.CppUtilities
not sure what to do from here…
any help would be good!
thanks,
udi.

here is my code:

package utilities

*import

public class CppUtilities

{

@Keyword

def checkIfEmailIsUsed(i)

{

i = i+1

WebDriver driver = DriverFactory.getWebDriver()

WebUI.setText(findTestObject(‘Sign up for a new account/input_email’), findTestData(‘New users’).getValue(4, i))

WebUI.setText(findTestObject(‘Sign up for a new account/input_password’), findTestData(‘New users’).getValue(5, i))

WebUI.setText(findTestObject(‘Sign up for a new account/input_confirm_password’), findTestData(‘New users’).getValue(5, 1))

WebUI.setText(findTestObject(‘Sign up for a new account/input_full_name’), findTestData(‘New users’).getValue(6, i))

WebUI.setText(findTestObject(‘Sign up for a new account/input_regkey’), findTestData(‘New users’).getValue(7, i))

WebUI.click(findTestObject(‘Sign up for a new account/button_Register’))

if(WebUI.verifyElementPresent(findTestObject(‘Sign up for a new account/Error handling/li_Email address is already re’),0))

{

i++

CustomKeywords.‘utilities.CppUtilities.checkIfEmailIsUsed’(i)

}

}

}

Udi,

I think if you want to use recursion approach, here are some example https://stackoverflow.com/questions/19764834/recursion-with-closures-in-groovy-2-1-9