私はCSharpがXamarinの言語だと知っていますが、時にはPythonのいくつかの機能が素晴らしいので、Xamarinの下でPythonスクリプトを起動したいと思っています。 私はironpythonを知っているので、試してみます。 IronPython.dll、IronPython.Module、Microsoft.Scripting.dll ...のようないくつかの必要なアセンブリを追加しました... 幸いにも、私はそれを正常に構築し、それは私のAndroidデバイス上で実行されます。 しかしでコードが実行すると:Xamarin.AndroidでPythonスクリプトを使用する方法はありますか?
ScriptEngine engine = Python.CreateEngine();
ScriptScope scope = engine.CreateScope();
ScriptSource source = engine.CreateScriptSourceFromString("");
source.Execute(scope);
エラーが発生しました:
Microsoft.Scripting.InvalidImplementationException:
Type 'IronPython.Runtime.PythonContext' doesn't provide a suitable public constructor or its implementation is faulty:
Could not load type 'IronPython.Runtime.PythonContext' from assembly 'IronPython, Version=2.7.5.0, Culture=neutral, PublicKeyToken=7f709c5b713576e1'.
ので、Xamarin.AndroidでPythonスクリプトを使用するには、いずれかの可能性はありますか?
これは、アーム・プロセッサ上のAndroid SDK用のJava仮想マシンと接続するxamarinランタイムにPythonランタイムを追加する?私はPythonの機能を想像することはできませんので、 "素晴らしい" 30MBの "Hello World"アプリを出荷したいと思います。 C#を学んでください。 – 323go