From: Devin Mullins Date: 2005-07-20T10:13:28+09:00 Subject: Re: Ruby/Rails as a starter language? Hal Fulton wrote: > Can you say this? > > bar = new clazz(); Object bar; try { bar = clazz.getConstructor(null).newInstance(null); } catch(NoSuchMethodException e) { //catch the checked exceptions ... } catch(InstantiationException e) { //or you could add these to the throws clause ... } catch(IllegalAccessException e) { //or you could catch Exception ... } catch(java.lang.reflect.InvocationTargetException e) { ... } > > And does getClass return you Foo or Foo.class? Foo.class Devin