-
-
Save ppazos/54bce66b78a9265ea69ce35541daa395 to your computer and use it in GitHub Desktop.
groovy: get an instance of a class from its name as a string
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def objectInstance = Class.forName("NAME.AS.STRING").newInstance() |
Author
ppazos
commented
Feb 11, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment