The code you have right now isn't particularly useful.
Line 23 - you get a name from the properties file
Line 25 - you add the name to a hard-coded package name; this limits the usefulness of the code because it assumes you are dealing with classes in the
student package
Line 27 - here you call a constructor directly to instantiate an
Employee; this further limits the code's usefulness because now it will only work with that class
Line 28 - here you hard-code the method you want to get a reference to; this makes the code even more specific to the implementation. This code won't work for any class that does not have a
showDetails method.
So why use a properties file at all if you're going to limit the utility of the rest of the code like this? What exactly are you trying to achieve here?
More importantly: are you just messing around with the Reflection API or is this for real-world code? If it's for the former, fine; read up on the Reflection API some more.
However, if it's for real-world code,
STOP IT!
I suspect there is something seriously lacking in your analysis and design if you have to resort to reflection and introspection when dealing with a class like
Employee.