/tutorial/cecil/JVM/Example1.java

http://github.com/tybor/Liberty · Java · 32 lines · 11 code · 5 blank · 16 comment · 0 complexity · 84b03493167eb940aa0b43f6e4e0958f MD5 · raw file

  1. import hello_world._any;
  2. import hello_world.hello_world;
  3. public class Example1 {
  4. /* To run this example, procede like this :
  5. compile_to_jvm hello_world
  6. /bin/rm -f hello_world.class
  7. javac Example1.java
  8. java Example1
  9. */
  10. public static void main(String[] args) {
  11. hello_world root;
  12. /* To initialize the Eiffel runtime :
  13. */
  14. _any._initialize_eiffel_runtime(args);
  15. /* Creation of the root object :
  16. */
  17. root = new hello_world();
  18. /* Launching the root procedure :
  19. */
  20. root.make();
  21. /* Launching again the root procedure :
  22. */
  23. root.make();
  24. }
  25. }