
上QQ阅读APP看书,第一时间看更新
Creating a Java class
Use the java-new-class command to add a non-final HelloJBossWorld class to the beosbank-forge-demo project:
[beosbank-forge-demo]$ java-new-class
***INFO*** Required inputs not satisfied, entering interactive mode? Package Name (The package name where this type will be created) [com.beosbank.forge.demo]: HIT ENTER
* Type Name (The type name): HelloJBossWorld
? Extends (The type used in the extends keyword):
? Interfaces []:
? Is Final? [y/N]: N
? Is Abstract? [y/N]: N
? Is Serializable? [y/N]: Y
***SUCCESS*** Class com.beosbank.forge.demo.HelloJBossWorld was created
[HelloJBossWorld.java]$
The new class is empty; you may wonder how to add attributes and methods to this newly created class using the Forge console.