如何导出 C# 方法? [英] How to export C# methods?

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

问题描述

我们如何导出 C# 方法?

How can we export C# methods?

我有一个 dll,我想在 Python 语言中通过 ctypes 模块使用它的方法.因为我需要使用 ctypes 模块,所以我需要导出 C# 方法以便它们在 Python 中可见.

I have a dll and I want to use its methods in the Python language with the ctypes module. Because I need to use the ctypes module, I need to export the C# methods for them to be visible in Python.

那么,我如何导出 C# 方法(就像它们在 C++ 中所做的那样)?

So, how can I export the C# methods (like they do in C++)?

推荐答案

与普遍看法相反,这可能的.
请参阅此处.

Contrary to popular belief, this is possible.
See here.

这篇关于如何导出 C# 方法?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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