insert JVM instruction

Discussions

General J2EE: insert JVM instruction

  1. insert JVM instruction (4 messages)

    How i can insert a JVM instructions in to my java code?
    What i will write before instruction ?

    Threaded Messages (4)

  2. insert JVM instruction[ Go to top ]

    I suppose you could hack the generated class file; the JVM architecture and its opcodes are well documented. But just out of interest, what opcodes are you trying to insert, and where? Why can't you achieve what you want to do in Java, or some other language that compiles to Java p-code?

    BTW in a sense you are always "inserting" an instruction when you write java because the JVM is a stack-based computer (that is what you see in the stack trace of an exception).
  3. insert JVM instruction[ Go to top ]

    I would create a custom classloader for this. The classloader would load some a kind of action class that implements an interface like:

    interface Action {
      public void execute();
    }

    the custom classloader could then each time a class is requested compile some java-code, and load the generated bytecode.

    Whit this you can do the, same more or less.

    Barri
  4. insert JVM instruction[ Go to top ]

    I have a problem! I want to create application for GSM (J2ME) - MIDP1.0.
      When the application close and time 5:00 become I want my midlet will be
      start. How to create this application? Where I show to application to start
      midlet in specific time?
    This is the reason why i want to insert JVM instructions in my java code. In MIDP2.0 have one class PushRegistry na metod registerAlarm() he turn to native metod addAlarm. But in MIDP1.0 and MIDP2.0 native metod are forbidden. I want in JVM instructions to turn metod addAlarm. :)))
    10x for your help :))
  5. BCEL[ Go to top ]

    http://jakarta.apache.org/bcel/