如何转换code,从C#到PHP [英] How to convert code from C# to PHP

查看:125
本文介绍了如何转换code,从C#到PHP的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有写在纯C#中的业务逻辑类(没有从这个语言的任何具体的东西),我想这code转换成PHP。我可以写我自己的解析器,但想到如果我能在我之前有人做到了。

I have a business logic classes that are written in pure C# (without any specific things from this language) and I would convert this code into PHP. I can write my own parser, but think if I could someone did it before me.

您能告诉我在哪里可以找到这种转换器的?

Could you please tell me where can I find this kind of converter?

诗。当我写我只使用普通的C#编程这门语言。只有参数,变量,方程和控制语句声明。

Ps. As I've written I use only plain C# programming in this language. Only arguments, declarations of variables, equations and control statements.

推荐答案

我知道你希望有人谁经历过但万一没有人来着...

I know you're hoping for someone who had experience but in case no one comes forward...

您可以考虑复制并粘贴code到PHP脚本并检查什么突破。写解析器解决这个问题,在整个脚本运行它,看看有什么是压垮接下来的事情。继续,直到达到预期的脚本功能。

You might consider just copy and pasting the code into a PHP script and checking what breaks. Write a parser to fix that, run it across the entire script, and see what's the next thing that breaks. Continue until the script functions as expected.

如果你不使用任何更多地参与.NET类的我无法想像你有太多的麻烦。

If you're not using any of the more involved .Net classes I can't imagine you'll have too much trouble.

这篇关于如何转换code,从C#到PHP的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆