问题描述
我们都知道Android运行Dalvik VM程序。
We all know that Android runs Dalvik VM programs.
通常开发人员用Java编写程序,并将其编译为Dalvik字节码。
Normally developers write programs in Java and they compile it to Dalvik bytecode.
我想知道是否可以创建一个可以接受C#代码并将其编译成Dalvik字节码的编译器。
I wonder if it would be possible to create a compiler that can take C# code and compile it into Dalvik bytecode.
推荐答案
好吧,这是一个选择 - 或者你可以运行它在运行在Android上的Mono。这已, 。我不确定细节 - 是否将运行Dalvik VM以及UI,无论它只是本机,或者它是否将是一个.NET到Dalvik编译器。
Well, that's one option - or you could just run it on Mono running on Android. This has already been done and the Mono team is now working on MonoDroid. I'm not sure of details yet - whether that will be running the Dalvik VM as well for UI, whether it will just be native, or whether it will be a .NET-to-Dalvik compiler.
这篇关于是否可以用C#编写Android应用程序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!