How do I change accessibility on an accessor using CodeDom?

◇◆丶佛笑我妖孽 提交于 2019-12-04 17:39:58

CodeDom doesn't directly support this. CodeDom dates from an era when C# and Visual Basic didn't support different accessibility on the get and set method, and hasn't been updated to support the new functionality. You will probably need to use a CodeSnippetTypeMember (though with a bit of ingenuity you could still use CodeDom to generate the getter and setter bodies).

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!