The Ax.java.Compiler class is a Java memory compiler. It is used to dinamically install a Java class in a classloader.

1 Example

The following example explains its usage:

Copy
var compiler = new Ax.java.Compiler();
    
        var logs = compiler.compile("deister.axional.script.lib.ax.java.HelloWorld", `
        
        package deister.axional.script.lib.ax.java;
        
        	public class HelloWorld {
        	  public HelloWorld() {
        	  }
        	  
        	  public String sayHello()
        	  {
        	     return "Hello";
        	  }
        	}
        
        `);
        
        console.log(logs);
        
        if (compiler.isCompiled()) {
        	console.log(new HelloWorld().sayHello());
        } else {
        	console.log("Compile failed");
        }