Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Instance name from string

Name: Anonymous 2011-01-20 17:00

Guys, I've been looking what feels like everywhere for an answer to this java.reflection problem.

I want to use the contents of a string to create and instance of an object that has the name of what the string stores.

Eg.
String[] carName = {"volvo","vw","bmw"};

car carName[0];
car carName[1];
car carName[2];

Name: Anonymous 2011-01-20 18:46

>>16
I think it's a legit question, actually.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List