I think you already tried yourself the first snippet and it threw NullPointerException. The only difference with using reflection it that it will work with a null reference if the method is static. If not static - you will get the exception again.
posted 13 years ago
Thanks Buddy, But the method is not static...so as you say there's probably no other way to do such thing. Thanks