Using a Java library with Scala reserved words

2020-01-26 11:04发布

问题:

I'm using an external library written in Java (Selenium). One of the function calls has the signature type(String, String), and I keep getting compiler errors when trying to call it from Scala, that is:

selenium.type("ab","abc")

Is there a workaround for this issue?

回答1:

selenium.`type`("ab","abc")