In C#, there's a method CreateInstance
of class Activator
which allows you to create an instance of the reflected type as it is shown here.
Is there a way to do the same tihing in Go programming language? I would like to take a type from a plugin (.so on Linux or .dll on Windows) by the name of the type and create an instance of this type in my code. How can I do that?
Aucun commentaire:
Enregistrer un commentaire