如何将.net属性应用于返回类型
如何将MarshalAsAttribute应用于下面代码的返回类型?
public ISomething Foo() { return new MyFoo(); }
根据https://msdn.microsoft.com/en-us/library/system.runtime.interopservices.marshalasattribute.aspx :
上述就是C#学习教程:如何将.net属性应用于返回类型分享的全部内容,如果对大家有所用处且需要了解更多关于C#学习教程,希望大家多多关注—计算机技术网(www.ctvol.com)!
[return: MarshalAs()] public ISomething Foo() { return new MyFoo(); }
[return:MarshalAs] public ISomething Foo() { return new MyFoo(); }
本文来自网络收集,不代表计算机技术网立场,如涉及侵权请联系管理员删除。
ctvol管理联系方式QQ:251552304
本文章地址:https://www.ctvol.com/cdevelopment/985742.html