Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Evaluate a script (e.g. Python) in Java for Android platform

Is it possible to evaluate a string of python code (or Perl) from Java when developing Android applications?

I am trying to do something like evaluating a text-input script:

String script = text1.getText().toString();
String result = PythonRuntime.evaluate(script);
text2.setText(result);
like image 319
Soni Ali Avatar asked Apr 19 '26 00:04

Soni Ali


1 Answers

In case you weren't aware of it, the Android Scripting Environment might be useful to you, though I don't think it does exactly what you're looking for.

like image 64
retracile Avatar answered Apr 20 '26 15:04

retracile



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!