0

Is there any way that I can execute arbitrary Java code from a String like Sql.exect(String). Is there something like Java.exect(String). Can anyone point me to a command or simple tutorial?

2 Answers 2

1

You can use Janino, take a look at here;

http://docs.codehaus.org/display/JANINO/Home

Sign up to request clarification or add additional context in comments.

1 Comment

is this work for android code like textviwe for example
1

I'm not sure if I understood you correctly, but maybe try to dig about this Java 6 Compiler API

2 Comments

does this work in android well for example i want String s = "int y = 3+6;" then something like Run(x)
Ok, It's not for Android. For that check this answer: stackoverflow.com/questions/17538537/…

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.