0

I am wondering what tools do I need to create new class based on user input (and named after it) in Java Application, with minimal usage of code? Example usage:

Provide name for class: apple
Class created: apple

Thanks

P.S I dont need the code - I will handle it myself. I am just wondering which tools should I use.

UPDATE
I have found this, though this only shows example of predifined classes. I would like to define new class.
UPDATE 2
In my case, I the new classes will inherit some of the properties of abstract class. Example: Abstract class Product, and new class 'ComputerProduct' that has access to the methods, and has its own implementations of this abstract class.

uksz
  • 18,239
  • 30
  • 94
  • 161

1 Answers1

1

You can use any of the Bytecode Library for this purpose. Most easy to use and which I prefer is JavaAssist.

BCEL is open source with Apache 2.0 license, hence you may explore this as well.

Vitthal Kavitake
  • 879
  • 5
  • 18