0

C# プロジェクトで使用されるインターフェイスを Visual C++ で作成する必要があります。C# で out パラメータを使用する必要があります。C++ 署名を作成するにはどうすればよいですか?

C++ コードのような

public interface class Iface
{
public:
    System::Object^ Method([out] bool there);
};

C# は

public class TestObj : Library.Iface
    {
        object Library.Iface.Method(out bool there)
        {
            there = true;
            return null;
        }
    }

C++ インターフェイスをどのように記述しますか?

4

1 に答える 1

3
using namespace System;
using namespace System::Runtime::InteropServices;
interface class Iface
{
    Object^ Method([Out] bool% there);
};
于 2012-06-20T13:22:58.400 に答える